<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.9.1"/>
<title>opennars: aruntime/src/main/java/nars/inference/SyllogisticRules.java Source File</title>
<link href="../../tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="../../jquery.js"></script>
<script type="text/javascript" src="../../dynsections.js"></script>
<link href="../../navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="../../resize.js"></script>
<script type="text/javascript" src="../../navtreedata.js"></script>
<script type="text/javascript" src="../../navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
  $(window).load(resizeHeight);
</script>
<link href="../../search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="../../search/searchdata.js"></script>
<script type="text/javascript" src="../../search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { init_search(); });
</script>
<link href="../../doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td style="padding-left: 0.5em;">
   <div id="projectname">opennars
   &#160;<span id="projectnumber">1.5.5</span>
   </div>
   <div id="projectbrief">1.5-ish</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.9.1 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "../../search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="../../index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="../../pages.html"><span>Related&#160;Pages</span></a></li>
      <li><a href="../../namespaces.html"><span>Packages</span></a></li>
      <li><a href="../../annotated.html"><span>Classes</span></a></li>
      <li class="current"><a href="../../files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="../../search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="../../search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="../../files.html"><span>File&#160;List</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('d4/d6b/SyllogisticRules_8java_source.html','../../');});
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="headertitle">
<div class="title">SyllogisticRules.java</div>  </div>
</div><!--header-->
<div class="contents">
<a href="../../d4/d6b/SyllogisticRules_8java.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;<span class="comment">/*</span></div>
<div class="line"><a name="l00002"></a><span class="lineno">    2</span>&#160;<span class="comment"> * SyllogisticRules.java</span></div>
<div class="line"><a name="l00003"></a><span class="lineno">    3</span>&#160;<span class="comment"> *</span></div>
<div class="line"><a name="l00004"></a><span class="lineno">    4</span>&#160;<span class="comment"> * Copyright (C) 2008  Pei Wang</span></div>
<div class="line"><a name="l00005"></a><span class="lineno">    5</span>&#160;<span class="comment"> *</span></div>
<div class="line"><a name="l00006"></a><span class="lineno">    6</span>&#160;<span class="comment"> * This file is part of Open-NARS.</span></div>
<div class="line"><a name="l00007"></a><span class="lineno">    7</span>&#160;<span class="comment"> *</span></div>
<div class="line"><a name="l00008"></a><span class="lineno">    8</span>&#160;<span class="comment"> * Open-NARS is free software; you can redistribute it and/or modify</span></div>
<div class="line"><a name="l00009"></a><span class="lineno">    9</span>&#160;<span class="comment"> * it under the terms of the GNU General Public License as published by</span></div>
<div class="line"><a name="l00010"></a><span class="lineno">   10</span>&#160;<span class="comment"> * the Free Software Foundation, either version 2 of the License, or</span></div>
<div class="line"><a name="l00011"></a><span class="lineno">   11</span>&#160;<span class="comment"> * (at your option) any later version.</span></div>
<div class="line"><a name="l00012"></a><span class="lineno">   12</span>&#160;<span class="comment"> *</span></div>
<div class="line"><a name="l00013"></a><span class="lineno">   13</span>&#160;<span class="comment"> * Open-NARS is distributed in the hope that it will be useful,</span></div>
<div class="line"><a name="l00014"></a><span class="lineno">   14</span>&#160;<span class="comment"> * but WITHOUT ANY WARRANTY; without even the abduction warranty of</span></div>
<div class="line"><a name="l00015"></a><span class="lineno">   15</span>&#160;<span class="comment"> * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the</span></div>
<div class="line"><a name="l00016"></a><span class="lineno">   16</span>&#160;<span class="comment"> * GNU General Public License for more details.</span></div>
<div class="line"><a name="l00017"></a><span class="lineno">   17</span>&#160;<span class="comment"> *</span></div>
<div class="line"><a name="l00018"></a><span class="lineno">   18</span>&#160;<span class="comment"> * You should have received a copy of the GNU General Public License</span></div>
<div class="line"><a name="l00019"></a><span class="lineno">   19</span>&#160;<span class="comment"> * along with Open-NARS.  If not, see &lt;http://www.gnu.org/licenses/&gt;.</span></div>
<div class="line"><a name="l00020"></a><span class="lineno">   20</span>&#160;<span class="comment"> */</span></div>
<div class="line"><a name="l00021"></a><span class="lineno">   21</span>&#160;<span class="keyword">package </span>nars.inference;</div>
<div class="line"><a name="l00022"></a><span class="lineno">   22</span>&#160;</div>
<div class="line"><a name="l00023"></a><span class="lineno">   23</span>&#160;<span class="keyword">import</span> <a class="code" href="../../d7/d81/namespacenars.html">nars</a>.<a class="code" href="../../db/dec/namespacenars_1_1entity.html">entity</a>.*;</div>
<div class="line"><a name="l00024"></a><span class="lineno">   24</span>&#160;<span class="keyword">import</span> <a class="code" href="../../d7/d81/namespacenars.html">nars</a>.<a class="code" href="../../d0/d72/namespacenars_1_1language.html">language</a>.*;</div>
<div class="line"><a name="l00025"></a><span class="lineno">   25</span>&#160;<span class="keyword">import</span> <a class="code" href="../../d7/d81/namespacenars.html">nars</a>.<a class="code" href="../../db/d64/namespacenars_1_1io.html">io</a>.<a class="code" href="../../dc/d71/classnars_1_1io_1_1Symbols.html">Symbols</a>;</div>
<div class="line"><a name="l00026"></a><span class="lineno">   26</span>&#160;<span class="keyword">import</span> <a class="code" href="../../d7/d81/namespacenars.html">nars</a>.<a class="code" href="../../de/ddc/namespacenars_1_1storage.html">storage</a>.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory.html">Memory</a>;</div>
<div class="line"><a name="l00027"></a><span class="lineno">   27</span>&#160;</div>
<div class="line"><a name="l00031"></a><span class="lineno"><a class="line" href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules.html">   31</a></span>&#160;<span class="keyword">public</span> <span class="keyword">final</span> <span class="keyword">class </span><a class="code" href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules.html">SyllogisticRules</a> {</div>
<div class="line"><a name="l00032"></a><span class="lineno">   32</span>&#160;</div>
<div class="line"><a name="l00033"></a><span class="lineno">   33</span>&#160;    <span class="comment">/*</span></div>
<div class="line"><a name="l00034"></a><span class="lineno">   34</span>&#160;<span class="comment">     * --------------- rules used in both first-tense inference and higher-tense</span></div>
<div class="line"><a name="l00035"></a><span class="lineno">   35</span>&#160;<span class="comment">     * inference ---------------</span></div>
<div class="line"><a name="l00036"></a><span class="lineno">   36</span>&#160;<span class="comment">     */</span></div>
<div class="line"><a name="l00053"></a><span class="lineno"><a class="line" href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules_a5724b3ed7e885c29110acceac0d677d5.html#a5724b3ed7e885c29110acceac0d677d5">   53</a></span>&#160;    <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules_a5724b3ed7e885c29110acceac0d677d5.html#a5724b3ed7e885c29110acceac0d677d5">dedExe</a>(<a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> term1, <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> term2, <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> sentence,</div>
<div class="line"><a name="l00054"></a><span class="lineno">   54</span>&#160;            <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> belief, <a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory.html">Memory</a> memory) {</div>
<div class="line"><a name="l00055"></a><span class="lineno">   55</span>&#160;        <span class="keywordflow">if</span> (<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_a96d4bf7bb99f48b6496cdb7457bc0e50.html#a96d4bf7bb99f48b6496cdb7457bc0e50">invalidStatement</a>(term1, term2)) {</div>
<div class="line"><a name="l00056"></a><span class="lineno">   56</span>&#160;            <span class="keywordflow">return</span>;</div>
<div class="line"><a name="l00057"></a><span class="lineno">   57</span>&#160;        }</div>
<div class="line"><a name="l00058"></a><span class="lineno">   58</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> value1 = sentence.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>();</div>
<div class="line"><a name="l00059"></a><span class="lineno">   59</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> value2 = belief.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>();</div>
<div class="line"><a name="l00060"></a><span class="lineno">   60</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> truth1 = null;</div>
<div class="line"><a name="l00061"></a><span class="lineno">   61</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> truth2 = null;</div>
<div class="line"><a name="l00062"></a><span class="lineno">   62</span>&#160;        <a class="code" href="../../db/d8e/classnars_1_1entity_1_1BudgetValue.html">BudgetValue</a> budget1, budget2;</div>
<div class="line"><a name="l00063"></a><span class="lineno">   63</span>&#160;        <span class="keywordflow">if</span> (sentence.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_acb98b40c8990dbe5e15061f0759c60ee.html#acb98b40c8990dbe5e15061f0759c60ee">isQuestion</a>()) {</div>
<div class="line"><a name="l00064"></a><span class="lineno">   64</span>&#160;            budget1 = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_a90343f7d4de3a6ffcd57493b7a09376f.html#a90343f7d4de3a6ffcd57493b7a09376f">backwardWeak</a>(value2, memory);</div>
<div class="line"><a name="l00065"></a><span class="lineno">   65</span>&#160;            budget2 = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_a90343f7d4de3a6ffcd57493b7a09376f.html#a90343f7d4de3a6ffcd57493b7a09376f">backwardWeak</a>(value2, memory);</div>
<div class="line"><a name="l00066"></a><span class="lineno">   66</span>&#160;        } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00067"></a><span class="lineno">   67</span>&#160;            truth1 = <a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions.html">TruthFunctions</a>.<a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_af0cd0f846c8a7e500840b517ab006b94.html#af0cd0f846c8a7e500840b517ab006b94">deduction</a>(value1, value2);</div>
<div class="line"><a name="l00068"></a><span class="lineno">   68</span>&#160;            truth2 = <a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions.html">TruthFunctions</a>.<a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_a54676ae3de8c6ef712566837b99d08a1.html#a54676ae3de8c6ef712566837b99d08a1">exemplification</a>(value1, value2);</div>
<div class="line"><a name="l00069"></a><span class="lineno">   69</span>&#160;            budget1 = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_ac3df7e788b7a6e2b348d2ae7da7936c5.html#ac3df7e788b7a6e2b348d2ae7da7936c5">forward</a>(truth1, memory);</div>
<div class="line"><a name="l00070"></a><span class="lineno">   70</span>&#160;            budget2 = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_ac3df7e788b7a6e2b348d2ae7da7936c5.html#ac3df7e788b7a6e2b348d2ae7da7936c5">forward</a>(truth2, memory);</div>
<div class="line"><a name="l00071"></a><span class="lineno">   71</span>&#160;        }</div>
<div class="line"><a name="l00072"></a><span class="lineno">   72</span>&#160;        <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a> content = (<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>) sentence.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_ad1ded9a02cae3557948d05530cd4d37e.html#ad1ded9a02cae3557948d05530cd4d37e">getContent</a>();</div>
<div class="line"><a name="l00073"></a><span class="lineno">   73</span>&#160;        <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a> content1 = <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_a4e4c29fc305a6741da88ce55fbf11e4a.html#a4e4c29fc305a6741da88ce55fbf11e4a">make</a>(content, term1, term2, memory);</div>
<div class="line"><a name="l00074"></a><span class="lineno">   74</span>&#160;        <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a> content2 = <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_a4e4c29fc305a6741da88ce55fbf11e4a.html#a4e4c29fc305a6741da88ce55fbf11e4a">make</a>(content, term2, term1, memory);</div>
<div class="line"><a name="l00075"></a><span class="lineno">   75</span>&#160;        memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_a077b38e451ff6e4217bdc2ff0bb08e70.html#a077b38e451ff6e4217bdc2ff0bb08e70">doublePremiseTask</a>(content1, truth1, budget1);</div>
<div class="line"><a name="l00076"></a><span class="lineno">   76</span>&#160;        memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_a077b38e451ff6e4217bdc2ff0bb08e70.html#a077b38e451ff6e4217bdc2ff0bb08e70">doublePremiseTask</a>(content2, truth2, budget2);</div>
<div class="line"><a name="l00077"></a><span class="lineno">   77</span>&#160;    }</div>
<div class="line"><a name="l00078"></a><span class="lineno">   78</span>&#160;</div>
<div class="line"><a name="l00097"></a><span class="lineno"><a class="line" href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules_a698f01981603a38d9da0e48930095d50.html#a698f01981603a38d9da0e48930095d50">   97</a></span>&#160;    <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules_a698f01981603a38d9da0e48930095d50.html#a698f01981603a38d9da0e48930095d50">abdIndCom</a>(<a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> term1, <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> term2, <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> taskSentence,</div>
<div class="line"><a name="l00098"></a><span class="lineno">   98</span>&#160;            <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> belief, <span class="keywordtype">int</span> figure, <a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory.html">Memory</a> memory) {</div>
<div class="line"><a name="l00099"></a><span class="lineno">   99</span>&#160;        <span class="keywordflow">if</span> (<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_a96d4bf7bb99f48b6496cdb7457bc0e50.html#a96d4bf7bb99f48b6496cdb7457bc0e50">invalidStatement</a>(term1, term2)) {</div>
<div class="line"><a name="l00100"></a><span class="lineno">  100</span>&#160;            <span class="keywordflow">return</span>;</div>
<div class="line"><a name="l00101"></a><span class="lineno">  101</span>&#160;        }</div>
<div class="line"><a name="l00102"></a><span class="lineno">  102</span>&#160;        <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a> taskContent = (<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>) taskSentence.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_ad1ded9a02cae3557948d05530cd4d37e.html#ad1ded9a02cae3557948d05530cd4d37e">getContent</a>();</div>
<div class="line"><a name="l00103"></a><span class="lineno">  103</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> truth1 = null;</div>
<div class="line"><a name="l00104"></a><span class="lineno">  104</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> truth2 = null;</div>
<div class="line"><a name="l00105"></a><span class="lineno">  105</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> truth3 = null;</div>
<div class="line"><a name="l00106"></a><span class="lineno">  106</span>&#160;        <a class="code" href="../../db/d8e/classnars_1_1entity_1_1BudgetValue.html">BudgetValue</a> budget1, budget2, budget3;</div>
<div class="line"><a name="l00107"></a><span class="lineno">  107</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> value1 = taskSentence.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>();</div>
<div class="line"><a name="l00108"></a><span class="lineno">  108</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> value2 = belief.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>();</div>
<div class="line"><a name="l00109"></a><span class="lineno">  109</span>&#160;        <span class="keywordflow">if</span> (taskSentence.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_acb98b40c8990dbe5e15061f0759c60ee.html#acb98b40c8990dbe5e15061f0759c60ee">isQuestion</a>()) {</div>
<div class="line"><a name="l00110"></a><span class="lineno">  110</span>&#160;            budget1 = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_a62ee0953b7880e2547458aa575e14161.html#a62ee0953b7880e2547458aa575e14161">backward</a>(value2, memory);</div>
<div class="line"><a name="l00111"></a><span class="lineno">  111</span>&#160;            budget2 = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_a90343f7d4de3a6ffcd57493b7a09376f.html#a90343f7d4de3a6ffcd57493b7a09376f">backwardWeak</a>(value2, memory);</div>
<div class="line"><a name="l00112"></a><span class="lineno">  112</span>&#160;            budget3 = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_a62ee0953b7880e2547458aa575e14161.html#a62ee0953b7880e2547458aa575e14161">backward</a>(value2, memory);</div>
<div class="line"><a name="l00113"></a><span class="lineno">  113</span>&#160;        } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00114"></a><span class="lineno">  114</span>&#160;            truth1 = <a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions.html">TruthFunctions</a>.<a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_ab001ba72b5926188d21dd48a5eaaeb8b.html#ab001ba72b5926188d21dd48a5eaaeb8b">abduction</a>(value1, value2);</div>
<div class="line"><a name="l00115"></a><span class="lineno">  115</span>&#160;            truth2 = <a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions.html">TruthFunctions</a>.<a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_ab001ba72b5926188d21dd48a5eaaeb8b.html#ab001ba72b5926188d21dd48a5eaaeb8b">abduction</a>(value2, value1);</div>
<div class="line"><a name="l00116"></a><span class="lineno">  116</span>&#160;            truth3 = <a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions.html">TruthFunctions</a>.<a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_a0eded294e31894aad09eb976587a20d3.html#a0eded294e31894aad09eb976587a20d3">comparison</a>(value1, value2);</div>
<div class="line"><a name="l00117"></a><span class="lineno">  117</span>&#160;            budget1 = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_ac3df7e788b7a6e2b348d2ae7da7936c5.html#ac3df7e788b7a6e2b348d2ae7da7936c5">forward</a>(truth1, memory);</div>
<div class="line"><a name="l00118"></a><span class="lineno">  118</span>&#160;            budget2 = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_ac3df7e788b7a6e2b348d2ae7da7936c5.html#ac3df7e788b7a6e2b348d2ae7da7936c5">forward</a>(truth2, memory);</div>
<div class="line"><a name="l00119"></a><span class="lineno">  119</span>&#160;            budget3 = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_ac3df7e788b7a6e2b348d2ae7da7936c5.html#ac3df7e788b7a6e2b348d2ae7da7936c5">forward</a>(truth3, memory);</div>
<div class="line"><a name="l00120"></a><span class="lineno">  120</span>&#160;        }</div>
<div class="line"><a name="l00121"></a><span class="lineno">  121</span>&#160;        <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a> statement1 = <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a></div>
<div class="line"><a name="l00122"></a><span class="lineno">  122</span>&#160;                .<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_a4e4c29fc305a6741da88ce55fbf11e4a.html#a4e4c29fc305a6741da88ce55fbf11e4a">make</a>(taskContent, term1, term2, memory);</div>
<div class="line"><a name="l00123"></a><span class="lineno">  123</span>&#160;        <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a> statement2 = <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a></div>
<div class="line"><a name="l00124"></a><span class="lineno">  124</span>&#160;                .<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_a4e4c29fc305a6741da88ce55fbf11e4a.html#a4e4c29fc305a6741da88ce55fbf11e4a">make</a>(taskContent, term2, term1, memory);</div>
<div class="line"><a name="l00125"></a><span class="lineno">  125</span>&#160;        <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a> statement3 = <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_a5cabf7120a4c6a0e94d18e436cbdc916.html#a5cabf7120a4c6a0e94d18e436cbdc916">makeSym</a>(taskContent, term1, term2,</div>
<div class="line"><a name="l00126"></a><span class="lineno">  126</span>&#160;                memory);</div>
<div class="line"><a name="l00127"></a><span class="lineno">  127</span>&#160;        memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_a077b38e451ff6e4217bdc2ff0bb08e70.html#a077b38e451ff6e4217bdc2ff0bb08e70">doublePremiseTask</a>(statement1, truth1, budget1);</div>
<div class="line"><a name="l00128"></a><span class="lineno">  128</span>&#160;        memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_a077b38e451ff6e4217bdc2ff0bb08e70.html#a077b38e451ff6e4217bdc2ff0bb08e70">doublePremiseTask</a>(statement2, truth2, budget2);</div>
<div class="line"><a name="l00129"></a><span class="lineno">  129</span>&#160;        memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_a077b38e451ff6e4217bdc2ff0bb08e70.html#a077b38e451ff6e4217bdc2ff0bb08e70">doublePremiseTask</a>(statement3, truth3, budget3);</div>
<div class="line"><a name="l00130"></a><span class="lineno">  130</span>&#160;    }</div>
<div class="line"><a name="l00131"></a><span class="lineno">  131</span>&#160;</div>
<div class="line"><a name="l00148"></a><span class="lineno"><a class="line" href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules_a9403109ff25044e65311d553d99a490d.html#a9403109ff25044e65311d553d99a490d">  148</a></span>&#160;    <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules_a9403109ff25044e65311d553d99a490d.html#a9403109ff25044e65311d553d99a490d">analogy</a>(<a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> term1, <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> term2, <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> asym, <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> sym,</div>
<div class="line"><a name="l00149"></a><span class="lineno">  149</span>&#160;            <span class="keywordtype">int</span> figure, <a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory.html">Memory</a> memory) {</div>
<div class="line"><a name="l00150"></a><span class="lineno">  150</span>&#160;        <span class="keywordflow">if</span> (<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_a96d4bf7bb99f48b6496cdb7457bc0e50.html#a96d4bf7bb99f48b6496cdb7457bc0e50">invalidStatement</a>(term1, term2)) {</div>
<div class="line"><a name="l00151"></a><span class="lineno">  151</span>&#160;            <span class="keywordflow">return</span>;</div>
<div class="line"><a name="l00152"></a><span class="lineno">  152</span>&#160;        }</div>
<div class="line"><a name="l00153"></a><span class="lineno">  153</span>&#160;        <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a> asymSt = (<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>) asym.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_ad1ded9a02cae3557948d05530cd4d37e.html#ad1ded9a02cae3557948d05530cd4d37e">getContent</a>();</div>
<div class="line"><a name="l00154"></a><span class="lineno">  154</span>&#160;        <span class="comment">// Statement symSt = (Statement) sym.getContent();</span></div>
<div class="line"><a name="l00155"></a><span class="lineno">  155</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> truth = null;</div>
<div class="line"><a name="l00156"></a><span class="lineno">  156</span>&#160;        <a class="code" href="../../db/d8e/classnars_1_1entity_1_1BudgetValue.html">BudgetValue</a> budget;</div>
<div class="line"><a name="l00157"></a><span class="lineno">  157</span>&#160;        <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> sentence = memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_a26eda4f00b333b706b4e3d069fdf1508.html#a26eda4f00b333b706b4e3d069fdf1508">getCurrentTask</a>().<a class="code" href="../../dc/ddc/classnars_1_1entity_1_1Task_ab140cb553a6cf40b07093d1df283567f.html#ab140cb553a6cf40b07093d1df283567f">getSentence</a>();</div>
<div class="line"><a name="l00158"></a><span class="lineno">  158</span>&#160;        <a class="code" href="../../d0/dee/classnars_1_1language_1_1CompoundTerm.html">CompoundTerm</a> taskTerm = (<a class="code" href="../../d0/dee/classnars_1_1language_1_1CompoundTerm.html">CompoundTerm</a>) sentence.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_ad1ded9a02cae3557948d05530cd4d37e.html#ad1ded9a02cae3557948d05530cd4d37e">getContent</a>();</div>
<div class="line"><a name="l00159"></a><span class="lineno">  159</span>&#160;        <span class="keywordflow">if</span> (sentence.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_acb98b40c8990dbe5e15061f0759c60ee.html#acb98b40c8990dbe5e15061f0759c60ee">isQuestion</a>()) {</div>
<div class="line"><a name="l00160"></a><span class="lineno">  160</span>&#160;            <span class="keywordflow">if</span> (taskTerm.<a class="code" href="../../d0/dee/classnars_1_1language_1_1CompoundTerm_a43c073fe9f5a36241c475a2bc8736800.html#a43c073fe9f5a36241c475a2bc8736800">isCommutative</a>()) {</div>
<div class="line"><a name="l00161"></a><span class="lineno">  161</span>&#160;                budget = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_a90343f7d4de3a6ffcd57493b7a09376f.html#a90343f7d4de3a6ffcd57493b7a09376f">backwardWeak</a>(asym.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>(), memory);</div>
<div class="line"><a name="l00162"></a><span class="lineno">  162</span>&#160;            } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00163"></a><span class="lineno">  163</span>&#160;                budget = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_a62ee0953b7880e2547458aa575e14161.html#a62ee0953b7880e2547458aa575e14161">backward</a>(sym.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>(), memory);</div>
<div class="line"><a name="l00164"></a><span class="lineno">  164</span>&#160;            }</div>
<div class="line"><a name="l00165"></a><span class="lineno">  165</span>&#160;        } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00166"></a><span class="lineno">  166</span>&#160;            truth = <a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions.html">TruthFunctions</a>.<a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_a93ca820557fc8d18ef741bd33501126f.html#a93ca820557fc8d18ef741bd33501126f">analogy</a>(asym.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>(), sym.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>());</div>
<div class="line"><a name="l00167"></a><span class="lineno">  167</span>&#160;            budget = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_ac3df7e788b7a6e2b348d2ae7da7936c5.html#ac3df7e788b7a6e2b348d2ae7da7936c5">forward</a>(truth, memory);</div>
<div class="line"><a name="l00168"></a><span class="lineno">  168</span>&#160;        }</div>
<div class="line"><a name="l00169"></a><span class="lineno">  169</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> content = <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_a4e4c29fc305a6741da88ce55fbf11e4a.html#a4e4c29fc305a6741da88ce55fbf11e4a">make</a>(asymSt, term1, term2, memory);</div>
<div class="line"><a name="l00170"></a><span class="lineno">  170</span>&#160;        memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_a077b38e451ff6e4217bdc2ff0bb08e70.html#a077b38e451ff6e4217bdc2ff0bb08e70">doublePremiseTask</a>(content, truth, budget);</div>
<div class="line"><a name="l00171"></a><span class="lineno">  171</span>&#160;    }</div>
<div class="line"><a name="l00172"></a><span class="lineno">  172</span>&#160;</div>
<div class="line"><a name="l00189"></a><span class="lineno"><a class="line" href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules_a171a1f81d7f22d9cd0301220a79f4a63.html#a171a1f81d7f22d9cd0301220a79f4a63">  189</a></span>&#160;    <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules_a171a1f81d7f22d9cd0301220a79f4a63.html#a171a1f81d7f22d9cd0301220a79f4a63">resemblance</a>(<a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> term1, <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> term2, <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> belief,</div>
<div class="line"><a name="l00190"></a><span class="lineno">  190</span>&#160;            <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> sentence, <span class="keywordtype">int</span> figure, <a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory.html">Memory</a> memory) {</div>
<div class="line"><a name="l00191"></a><span class="lineno">  191</span>&#160;        <span class="keywordflow">if</span> (<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_a96d4bf7bb99f48b6496cdb7457bc0e50.html#a96d4bf7bb99f48b6496cdb7457bc0e50">invalidStatement</a>(term1, term2)) {</div>
<div class="line"><a name="l00192"></a><span class="lineno">  192</span>&#160;            <span class="keywordflow">return</span>;</div>
<div class="line"><a name="l00193"></a><span class="lineno">  193</span>&#160;        }</div>
<div class="line"><a name="l00194"></a><span class="lineno">  194</span>&#160;        <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a> st1 = (<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>) belief.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_ad1ded9a02cae3557948d05530cd4d37e.html#ad1ded9a02cae3557948d05530cd4d37e">getContent</a>();</div>
<div class="line"><a name="l00195"></a><span class="lineno">  195</span>&#160;        <span class="comment">// Statement st2 = (Statement) sentence.getContent();</span></div>
<div class="line"><a name="l00196"></a><span class="lineno">  196</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> truth = null;</div>
<div class="line"><a name="l00197"></a><span class="lineno">  197</span>&#160;        <a class="code" href="../../db/d8e/classnars_1_1entity_1_1BudgetValue.html">BudgetValue</a> budget;</div>
<div class="line"><a name="l00198"></a><span class="lineno">  198</span>&#160;        <span class="keywordflow">if</span> (sentence.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_acb98b40c8990dbe5e15061f0759c60ee.html#acb98b40c8990dbe5e15061f0759c60ee">isQuestion</a>()) {</div>
<div class="line"><a name="l00199"></a><span class="lineno">  199</span>&#160;            budget = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_a62ee0953b7880e2547458aa575e14161.html#a62ee0953b7880e2547458aa575e14161">backward</a>(belief.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>(), memory);</div>
<div class="line"><a name="l00200"></a><span class="lineno">  200</span>&#160;        } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00201"></a><span class="lineno">  201</span>&#160;            truth = <a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions.html">TruthFunctions</a>.<a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_a6c1cb2626ef3303a17b5bc84c9da732f.html#a6c1cb2626ef3303a17b5bc84c9da732f">resemblance</a>(belief.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>(),</div>
<div class="line"><a name="l00202"></a><span class="lineno">  202</span>&#160;                    sentence.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>());</div>
<div class="line"><a name="l00203"></a><span class="lineno">  203</span>&#160;            budget = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_ac3df7e788b7a6e2b348d2ae7da7936c5.html#ac3df7e788b7a6e2b348d2ae7da7936c5">forward</a>(truth, memory);</div>
<div class="line"><a name="l00204"></a><span class="lineno">  204</span>&#160;        }</div>
<div class="line"><a name="l00205"></a><span class="lineno">  205</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> statement = <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_a4e4c29fc305a6741da88ce55fbf11e4a.html#a4e4c29fc305a6741da88ce55fbf11e4a">make</a>(st1, term1, term2, memory);</div>
<div class="line"><a name="l00206"></a><span class="lineno">  206</span>&#160;        memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_a077b38e451ff6e4217bdc2ff0bb08e70.html#a077b38e451ff6e4217bdc2ff0bb08e70">doublePremiseTask</a>(statement, truth, budget);</div>
<div class="line"><a name="l00207"></a><span class="lineno">  207</span>&#160;    }</div>
<div class="line"><a name="l00208"></a><span class="lineno">  208</span>&#160;</div>
<div class="line"><a name="l00209"></a><span class="lineno">  209</span>&#160;    <span class="comment">/* --------------- rules used only in conditional inference --------------- */</span></div>
<div class="line"><a name="l00224"></a><span class="lineno"><a class="line" href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules_a08c8ce3ed165e9c09a7a379d9e871626.html#a08c8ce3ed165e9c09a7a379d9e871626">  224</a></span>&#160;    <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules_a08c8ce3ed165e9c09a7a379d9e871626.html#a08c8ce3ed165e9c09a7a379d9e871626">detachment</a>(<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> mainSentence, <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> subSentence,</div>
<div class="line"><a name="l00225"></a><span class="lineno">  225</span>&#160;            <span class="keywordtype">int</span> side, <a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory.html">Memory</a> memory) {</div>
<div class="line"><a name="l00226"></a><span class="lineno">  226</span>&#160;        <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a> statement = (<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>) mainSentence.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_ad1ded9a02cae3557948d05530cd4d37e.html#ad1ded9a02cae3557948d05530cd4d37e">getContent</a>();</div>
<div class="line"><a name="l00227"></a><span class="lineno">  227</span>&#160;        <span class="keywordflow">if</span> (!(statement instanceof <a class="code" href="../../da/db6/classnars_1_1language_1_1Implication.html">Implication</a>)</div>
<div class="line"><a name="l00228"></a><span class="lineno">  228</span>&#160;                &amp;&amp; !(statement instanceof <a class="code" href="../../d1/d8b/classnars_1_1language_1_1Equivalence.html">Equivalence</a>)) {</div>
<div class="line"><a name="l00229"></a><span class="lineno">  229</span>&#160;            <span class="keywordflow">return</span>;</div>
<div class="line"><a name="l00230"></a><span class="lineno">  230</span>&#160;        }</div>
<div class="line"><a name="l00231"></a><span class="lineno">  231</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> subject = statement.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_ace4f80751d303c613e467163913bebf5.html#ace4f80751d303c613e467163913bebf5">getSubject</a>();</div>
<div class="line"><a name="l00232"></a><span class="lineno">  232</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> predicate = statement.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_ababe6155e2f78e769f76493317e118e0.html#ababe6155e2f78e769f76493317e118e0">getPredicate</a>();</div>
<div class="line"><a name="l00233"></a><span class="lineno">  233</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> content;</div>
<div class="line"><a name="l00234"></a><span class="lineno">  234</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> term = subSentence.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_ad1ded9a02cae3557948d05530cd4d37e.html#ad1ded9a02cae3557948d05530cd4d37e">getContent</a>();</div>
<div class="line"><a name="l00235"></a><span class="lineno">  235</span>&#160;        <span class="keywordflow">if</span> ((side == 0) &amp;&amp; term.<a class="code" href="../../d8/db8/classnars_1_1language_1_1Term_ad85f45a7858737445d5158801774ff5f.html#ad85f45a7858737445d5158801774ff5f">equals</a>(subject)) {</div>
<div class="line"><a name="l00236"></a><span class="lineno">  236</span>&#160;            content = predicate;</div>
<div class="line"><a name="l00237"></a><span class="lineno">  237</span>&#160;        } <span class="keywordflow">else</span> <span class="keywordflow">if</span> ((side == 1) &amp;&amp; term.<a class="code" href="../../d8/db8/classnars_1_1language_1_1Term_ad85f45a7858737445d5158801774ff5f.html#ad85f45a7858737445d5158801774ff5f">equals</a>(predicate)) {</div>
<div class="line"><a name="l00238"></a><span class="lineno">  238</span>&#160;            content = subject;</div>
<div class="line"><a name="l00239"></a><span class="lineno">  239</span>&#160;        } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00240"></a><span class="lineno">  240</span>&#160;            <span class="keywordflow">return</span>;</div>
<div class="line"><a name="l00241"></a><span class="lineno">  241</span>&#160;        }</div>
<div class="line"><a name="l00242"></a><span class="lineno">  242</span>&#160;        <span class="keywordflow">if</span> ((content instanceof <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>) &amp;&amp; ((Statement) content).invalid()) {</div>
<div class="line"><a name="l00243"></a><span class="lineno">  243</span>&#160;            <span class="keywordflow">return</span>;</div>
<div class="line"><a name="l00244"></a><span class="lineno">  244</span>&#160;        }</div>
<div class="line"><a name="l00245"></a><span class="lineno">  245</span>&#160;        <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> taskSentence = memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_a26eda4f00b333b706b4e3d069fdf1508.html#a26eda4f00b333b706b4e3d069fdf1508">getCurrentTask</a>().<a class="code" href="../../dc/ddc/classnars_1_1entity_1_1Task_ab140cb553a6cf40b07093d1df283567f.html#ab140cb553a6cf40b07093d1df283567f">getSentence</a>();</div>
<div class="line"><a name="l00246"></a><span class="lineno">  246</span>&#160;        <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> beliefSentence = memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_aae366ea198c2340fef786120d5c2163b.html#aae366ea198c2340fef786120d5c2163b">getCurrentBelief</a>();</div>
<div class="line"><a name="l00247"></a><span class="lineno">  247</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> beliefTruth = beliefSentence.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>();</div>
<div class="line"><a name="l00248"></a><span class="lineno">  248</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> truth1 = mainSentence.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>();</div>
<div class="line"><a name="l00249"></a><span class="lineno">  249</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> truth2 = subSentence.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>();</div>
<div class="line"><a name="l00250"></a><span class="lineno">  250</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> truth = null;</div>
<div class="line"><a name="l00251"></a><span class="lineno">  251</span>&#160;        <a class="code" href="../../db/d8e/classnars_1_1entity_1_1BudgetValue.html">BudgetValue</a> budget;</div>
<div class="line"><a name="l00252"></a><span class="lineno">  252</span>&#160;        <span class="keywordflow">if</span> (taskSentence.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_acb98b40c8990dbe5e15061f0759c60ee.html#acb98b40c8990dbe5e15061f0759c60ee">isQuestion</a>()) {</div>
<div class="line"><a name="l00253"></a><span class="lineno">  253</span>&#160;            <span class="keywordflow">if</span> (statement instanceof Equivalence) {</div>
<div class="line"><a name="l00254"></a><span class="lineno">  254</span>&#160;                budget = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_a62ee0953b7880e2547458aa575e14161.html#a62ee0953b7880e2547458aa575e14161">backward</a>(beliefTruth, memory);</div>
<div class="line"><a name="l00255"></a><span class="lineno">  255</span>&#160;            } <span class="keywordflow">else</span> <span class="keywordflow">if</span> (side == 0) {</div>
<div class="line"><a name="l00256"></a><span class="lineno">  256</span>&#160;                budget = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_a90343f7d4de3a6ffcd57493b7a09376f.html#a90343f7d4de3a6ffcd57493b7a09376f">backwardWeak</a>(beliefTruth, memory);</div>
<div class="line"><a name="l00257"></a><span class="lineno">  257</span>&#160;            } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00258"></a><span class="lineno">  258</span>&#160;                budget = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_a62ee0953b7880e2547458aa575e14161.html#a62ee0953b7880e2547458aa575e14161">backward</a>(beliefTruth, memory);</div>
<div class="line"><a name="l00259"></a><span class="lineno">  259</span>&#160;            }</div>
<div class="line"><a name="l00260"></a><span class="lineno">  260</span>&#160;        } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00261"></a><span class="lineno">  261</span>&#160;            <span class="keywordflow">if</span> (statement instanceof Equivalence) {</div>
<div class="line"><a name="l00262"></a><span class="lineno">  262</span>&#160;                truth = <a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions.html">TruthFunctions</a>.<a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_a93ca820557fc8d18ef741bd33501126f.html#a93ca820557fc8d18ef741bd33501126f">analogy</a>(truth2, truth1);</div>
<div class="line"><a name="l00263"></a><span class="lineno">  263</span>&#160;            } <span class="keywordflow">else</span> <span class="keywordflow">if</span> (side == 0) {</div>
<div class="line"><a name="l00264"></a><span class="lineno">  264</span>&#160;                truth = <a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions.html">TruthFunctions</a>.<a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_af0cd0f846c8a7e500840b517ab006b94.html#af0cd0f846c8a7e500840b517ab006b94">deduction</a>(truth1, truth2);</div>
<div class="line"><a name="l00265"></a><span class="lineno">  265</span>&#160;            } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00266"></a><span class="lineno">  266</span>&#160;                truth = <a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions.html">TruthFunctions</a>.<a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_ab001ba72b5926188d21dd48a5eaaeb8b.html#ab001ba72b5926188d21dd48a5eaaeb8b">abduction</a>(truth2, truth1);</div>
<div class="line"><a name="l00267"></a><span class="lineno">  267</span>&#160;            }</div>
<div class="line"><a name="l00268"></a><span class="lineno">  268</span>&#160;            budget = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_ac3df7e788b7a6e2b348d2ae7da7936c5.html#ac3df7e788b7a6e2b348d2ae7da7936c5">forward</a>(truth, memory);</div>
<div class="line"><a name="l00269"></a><span class="lineno">  269</span>&#160;        }</div>
<div class="line"><a name="l00270"></a><span class="lineno">  270</span>&#160;        memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_a077b38e451ff6e4217bdc2ff0bb08e70.html#a077b38e451ff6e4217bdc2ff0bb08e70">doublePremiseTask</a>(content, truth, budget);</div>
<div class="line"><a name="l00271"></a><span class="lineno">  271</span>&#160;    }</div>
<div class="line"><a name="l00272"></a><span class="lineno">  272</span>&#160;</div>
<div class="line"><a name="l00291"></a><span class="lineno"><a class="line" href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules_a6ee55e2d5114b506fdf5c59ae00dcd19.html#a6ee55e2d5114b506fdf5c59ae00dcd19">  291</a></span>&#160;    <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules_a6ee55e2d5114b506fdf5c59ae00dcd19.html#a6ee55e2d5114b506fdf5c59ae00dcd19">conditionalDedInd</a>(<a class="code" href="../../da/db6/classnars_1_1language_1_1Implication.html">Implication</a> premise1, <span class="keywordtype">short</span> index,</div>
<div class="line"><a name="l00292"></a><span class="lineno">  292</span>&#160;            <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> premise2, <span class="keywordtype">int</span> side, <a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory.html">Memory</a> memory) {</div>
<div class="line"><a name="l00293"></a><span class="lineno">  293</span>&#160;        <a class="code" href="../../dc/ddc/classnars_1_1entity_1_1Task.html">Task</a> task = memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_a26eda4f00b333b706b4e3d069fdf1508.html#a26eda4f00b333b706b4e3d069fdf1508">getCurrentTask</a>();</div>
<div class="line"><a name="l00294"></a><span class="lineno">  294</span>&#160;        <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> taskSentence = task.<a class="code" href="../../dc/ddc/classnars_1_1entity_1_1Task_ab140cb553a6cf40b07093d1df283567f.html#ab140cb553a6cf40b07093d1df283567f">getSentence</a>();</div>
<div class="line"><a name="l00295"></a><span class="lineno">  295</span>&#160;        <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> belief = memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_aae366ea198c2340fef786120d5c2163b.html#aae366ea198c2340fef786120d5c2163b">getCurrentBelief</a>();</div>
<div class="line"><a name="l00296"></a><span class="lineno">  296</span>&#160;        <span class="keywordtype">boolean</span> deduction = (side != 0);</div>
<div class="line"><a name="l00297"></a><span class="lineno">  297</span>&#160;        <span class="keywordtype">boolean</span> conditionalTask = <a class="code" href="../../de/da5/classnars_1_1language_1_1Variable.html">Variable</a>.<a class="code" href="../../de/da5/classnars_1_1language_1_1Variable_a27d52c132400491e698146c554cd89ac.html#a27d52c132400491e698146c554cd89ac">hasSubstitute</a>(</div>
<div class="line"><a name="l00298"></a><span class="lineno">  298</span>&#160;                <a class="code" href="../../dc/d71/classnars_1_1io_1_1Symbols.html">Symbols</a>.<a class="code" href="../../dc/d71/classnars_1_1io_1_1Symbols_a60c92a89535a54f54a72e20a5969536d.html#a60c92a89535a54f54a72e20a5969536d">VAR_INDEPENDENT</a>, premise2, belief.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_ad1ded9a02cae3557948d05530cd4d37e.html#ad1ded9a02cae3557948d05530cd4d37e">getContent</a>());</div>
<div class="line"><a name="l00299"></a><span class="lineno">  299</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> commonComponent;</div>
<div class="line"><a name="l00300"></a><span class="lineno">  300</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> newComponent = null;</div>
<div class="line"><a name="l00301"></a><span class="lineno">  301</span>&#160;        <span class="keywordflow">if</span> (side == 0) {</div>
<div class="line"><a name="l00302"></a><span class="lineno">  302</span>&#160;            commonComponent = ((<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>) premise2).getSubject();</div>
<div class="line"><a name="l00303"></a><span class="lineno">  303</span>&#160;            newComponent = ((<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>) premise2).getPredicate();</div>
<div class="line"><a name="l00304"></a><span class="lineno">  304</span>&#160;        } <span class="keywordflow">else</span> <span class="keywordflow">if</span> (side == 1) {</div>
<div class="line"><a name="l00305"></a><span class="lineno">  305</span>&#160;            commonComponent = ((<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>) premise2).getPredicate();</div>
<div class="line"><a name="l00306"></a><span class="lineno">  306</span>&#160;            newComponent = ((<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>) premise2).getSubject();</div>
<div class="line"><a name="l00307"></a><span class="lineno">  307</span>&#160;        } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00308"></a><span class="lineno">  308</span>&#160;            commonComponent = premise2;</div>
<div class="line"><a name="l00309"></a><span class="lineno">  309</span>&#160;        }</div>
<div class="line"><a name="l00310"></a><span class="lineno">  310</span>&#160;        <a class="code" href="../../d6/d98/classnars_1_1language_1_1Conjunction.html">Conjunction</a> oldCondition = (<a class="code" href="../../d6/d98/classnars_1_1language_1_1Conjunction.html">Conjunction</a>) premise1.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_ace4f80751d303c613e467163913bebf5.html#ace4f80751d303c613e467163913bebf5">getSubject</a>();</div>
<div class="line"><a name="l00311"></a><span class="lineno">  311</span>&#160;        <span class="keywordtype">int</span> index2 = oldCondition.<a class="code" href="../../d0/dee/classnars_1_1language_1_1CompoundTerm_a9778c35f9b602bee6ccac6a06809e546.html#a9778c35f9b602bee6ccac6a06809e546">getComponents</a>().indexOf(commonComponent);</div>
<div class="line"><a name="l00312"></a><span class="lineno">  312</span>&#160;        <span class="keywordflow">if</span> (index2 &gt;= 0) {</div>
<div class="line"><a name="l00313"></a><span class="lineno">  313</span>&#160;            index = (short) index2;</div>
<div class="line"><a name="l00314"></a><span class="lineno">  314</span>&#160;        } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00315"></a><span class="lineno">  315</span>&#160;            <span class="keywordtype">boolean</span> match = <a class="code" href="../../de/da5/classnars_1_1language_1_1Variable.html">Variable</a>.<a class="code" href="../../de/da5/classnars_1_1language_1_1Variable_a2770bbc76b3aac48f49a1c15aaedab1b.html#a2770bbc76b3aac48f49a1c15aaedab1b">unify</a>(<a class="code" href="../../dc/d71/classnars_1_1io_1_1Symbols.html">Symbols</a>.<a class="code" href="../../dc/d71/classnars_1_1io_1_1Symbols_a60c92a89535a54f54a72e20a5969536d.html#a60c92a89535a54f54a72e20a5969536d">VAR_INDEPENDENT</a>,</div>
<div class="line"><a name="l00316"></a><span class="lineno">  316</span>&#160;                    oldCondition.<a class="code" href="../../d0/dee/classnars_1_1language_1_1CompoundTerm_acedae916705e9fa1669391a7d728b840.html#acedae916705e9fa1669391a7d728b840">componentAt</a>(index), commonComponent, premise1,</div>
<div class="line"><a name="l00317"></a><span class="lineno">  317</span>&#160;                    premise2);</div>
<div class="line"><a name="l00318"></a><span class="lineno">  318</span>&#160;            <span class="keywordflow">if</span> (!match</div>
<div class="line"><a name="l00319"></a><span class="lineno">  319</span>&#160;                    &amp;&amp; (commonComponent.getClass() == oldCondition.getClass())) {</div>
<div class="line"><a name="l00320"></a><span class="lineno">  320</span>&#160;                match = <a class="code" href="../../de/da5/classnars_1_1language_1_1Variable.html">Variable</a>.<a class="code" href="../../de/da5/classnars_1_1language_1_1Variable_a2770bbc76b3aac48f49a1c15aaedab1b.html#a2770bbc76b3aac48f49a1c15aaedab1b">unify</a>(<a class="code" href="../../dc/d71/classnars_1_1io_1_1Symbols.html">Symbols</a>.<a class="code" href="../../dc/d71/classnars_1_1io_1_1Symbols_a60c92a89535a54f54a72e20a5969536d.html#a60c92a89535a54f54a72e20a5969536d">VAR_INDEPENDENT</a>,</div>
<div class="line"><a name="l00321"></a><span class="lineno">  321</span>&#160;                        oldCondition.<a class="code" href="../../d0/dee/classnars_1_1language_1_1CompoundTerm_acedae916705e9fa1669391a7d728b840.html#acedae916705e9fa1669391a7d728b840">componentAt</a>(index),</div>
<div class="line"><a name="l00322"></a><span class="lineno">  322</span>&#160;                        ((<a class="code" href="../../d0/dee/classnars_1_1language_1_1CompoundTerm.html">CompoundTerm</a>) commonComponent).componentAt(index),</div>
<div class="line"><a name="l00323"></a><span class="lineno">  323</span>&#160;                        premise1, premise2);</div>
<div class="line"><a name="l00324"></a><span class="lineno">  324</span>&#160;            }</div>
<div class="line"><a name="l00325"></a><span class="lineno">  325</span>&#160;            <span class="keywordflow">if</span> (!match) {</div>
<div class="line"><a name="l00326"></a><span class="lineno">  326</span>&#160;                <span class="keywordflow">return</span>;</div>
<div class="line"><a name="l00327"></a><span class="lineno">  327</span>&#160;            }</div>
<div class="line"><a name="l00328"></a><span class="lineno">  328</span>&#160;        }</div>
<div class="line"><a name="l00329"></a><span class="lineno">  329</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> newCondition;</div>
<div class="line"><a name="l00330"></a><span class="lineno">  330</span>&#160;        <span class="keywordflow">if</span> (oldCondition.<a class="code" href="../../d8/db8/classnars_1_1language_1_1Term_ad85f45a7858737445d5158801774ff5f.html#ad85f45a7858737445d5158801774ff5f">equals</a>(commonComponent)) {</div>
<div class="line"><a name="l00331"></a><span class="lineno">  331</span>&#160;            newCondition = null;</div>
<div class="line"><a name="l00332"></a><span class="lineno">  332</span>&#160;        } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00333"></a><span class="lineno">  333</span>&#160;            newCondition = <a class="code" href="../../d0/dee/classnars_1_1language_1_1CompoundTerm.html">CompoundTerm</a>.<a class="code" href="../../d0/dee/classnars_1_1language_1_1CompoundTerm_a623c88183d85bd42464640937ea8ccb5.html#a623c88183d85bd42464640937ea8ccb5">setComponent</a>(oldCondition, index,</div>
<div class="line"><a name="l00334"></a><span class="lineno">  334</span>&#160;                    newComponent, memory);</div>
<div class="line"><a name="l00335"></a><span class="lineno">  335</span>&#160;        }</div>
<div class="line"><a name="l00336"></a><span class="lineno">  336</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> content;</div>
<div class="line"><a name="l00337"></a><span class="lineno">  337</span>&#160;        <span class="keywordflow">if</span> (newCondition != null) {</div>
<div class="line"><a name="l00338"></a><span class="lineno">  338</span>&#160;            content = <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_a4e4c29fc305a6741da88ce55fbf11e4a.html#a4e4c29fc305a6741da88ce55fbf11e4a">make</a>(premise1, newCondition,</div>
<div class="line"><a name="l00339"></a><span class="lineno">  339</span>&#160;                    premise1.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_ababe6155e2f78e769f76493317e118e0.html#ababe6155e2f78e769f76493317e118e0">getPredicate</a>(), memory);</div>
<div class="line"><a name="l00340"></a><span class="lineno">  340</span>&#160;        } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00341"></a><span class="lineno">  341</span>&#160;            content = premise1.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_ababe6155e2f78e769f76493317e118e0.html#ababe6155e2f78e769f76493317e118e0">getPredicate</a>();</div>
<div class="line"><a name="l00342"></a><span class="lineno">  342</span>&#160;        }</div>
<div class="line"><a name="l00343"></a><span class="lineno">  343</span>&#160;        <span class="keywordflow">if</span> (content == null) {</div>
<div class="line"><a name="l00344"></a><span class="lineno">  344</span>&#160;            <span class="keywordflow">return</span>;</div>
<div class="line"><a name="l00345"></a><span class="lineno">  345</span>&#160;        }</div>
<div class="line"><a name="l00346"></a><span class="lineno">  346</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> truth1 = taskSentence.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>();</div>
<div class="line"><a name="l00347"></a><span class="lineno">  347</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> truth2 = belief.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>();</div>
<div class="line"><a name="l00348"></a><span class="lineno">  348</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> truth = null;</div>
<div class="line"><a name="l00349"></a><span class="lineno">  349</span>&#160;        <a class="code" href="../../db/d8e/classnars_1_1entity_1_1BudgetValue.html">BudgetValue</a> budget;</div>
<div class="line"><a name="l00350"></a><span class="lineno">  350</span>&#160;        <span class="keywordflow">if</span> (taskSentence.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_acb98b40c8990dbe5e15061f0759c60ee.html#acb98b40c8990dbe5e15061f0759c60ee">isQuestion</a>()) {</div>
<div class="line"><a name="l00351"></a><span class="lineno">  351</span>&#160;            budget = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_a90343f7d4de3a6ffcd57493b7a09376f.html#a90343f7d4de3a6ffcd57493b7a09376f">backwardWeak</a>(truth2, memory);</div>
<div class="line"><a name="l00352"></a><span class="lineno">  352</span>&#160;        } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00353"></a><span class="lineno">  353</span>&#160;            <span class="keywordflow">if</span> (deduction) {</div>
<div class="line"><a name="l00354"></a><span class="lineno">  354</span>&#160;                truth = <a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions.html">TruthFunctions</a>.<a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_af0cd0f846c8a7e500840b517ab006b94.html#af0cd0f846c8a7e500840b517ab006b94">deduction</a>(truth1, truth2);</div>
<div class="line"><a name="l00355"></a><span class="lineno">  355</span>&#160;            } <span class="keywordflow">else</span> <span class="keywordflow">if</span> (conditionalTask) {</div>
<div class="line"><a name="l00356"></a><span class="lineno">  356</span>&#160;                truth = <a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions.html">TruthFunctions</a>.<a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_aed67308b830f5b1780c075f2736f3ad0.html#aed67308b830f5b1780c075f2736f3ad0">induction</a>(truth2, truth1);</div>
<div class="line"><a name="l00357"></a><span class="lineno">  357</span>&#160;            } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00358"></a><span class="lineno">  358</span>&#160;                truth = <a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions.html">TruthFunctions</a>.<a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_aed67308b830f5b1780c075f2736f3ad0.html#aed67308b830f5b1780c075f2736f3ad0">induction</a>(truth1, truth2);</div>
<div class="line"><a name="l00359"></a><span class="lineno">  359</span>&#160;            }</div>
<div class="line"><a name="l00360"></a><span class="lineno">  360</span>&#160;            budget = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_ac3df7e788b7a6e2b348d2ae7da7936c5.html#ac3df7e788b7a6e2b348d2ae7da7936c5">forward</a>(truth, memory);</div>
<div class="line"><a name="l00361"></a><span class="lineno">  361</span>&#160;        }</div>
<div class="line"><a name="l00362"></a><span class="lineno">  362</span>&#160;        memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_a077b38e451ff6e4217bdc2ff0bb08e70.html#a077b38e451ff6e4217bdc2ff0bb08e70">doublePremiseTask</a>(content, truth, budget);</div>
<div class="line"><a name="l00363"></a><span class="lineno">  363</span>&#160;    }</div>
<div class="line"><a name="l00364"></a><span class="lineno">  364</span>&#160;</div>
<div class="line"><a name="l00381"></a><span class="lineno"><a class="line" href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules_a90588e33b6d7ca522e787ee476a2a012.html#a90588e33b6d7ca522e787ee476a2a012">  381</a></span>&#160;    <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules_a90588e33b6d7ca522e787ee476a2a012.html#a90588e33b6d7ca522e787ee476a2a012">conditionalAna</a>(<a class="code" href="../../d1/d8b/classnars_1_1language_1_1Equivalence.html">Equivalence</a> premise1, <span class="keywordtype">short</span> index,</div>
<div class="line"><a name="l00382"></a><span class="lineno">  382</span>&#160;            <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> premise2, <span class="keywordtype">int</span> side, <a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory.html">Memory</a> memory) {</div>
<div class="line"><a name="l00383"></a><span class="lineno">  383</span>&#160;        <a class="code" href="../../dc/ddc/classnars_1_1entity_1_1Task.html">Task</a> task = memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_a26eda4f00b333b706b4e3d069fdf1508.html#a26eda4f00b333b706b4e3d069fdf1508">getCurrentTask</a>();</div>
<div class="line"><a name="l00384"></a><span class="lineno">  384</span>&#160;        <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> taskSentence = task.<a class="code" href="../../dc/ddc/classnars_1_1entity_1_1Task_ab140cb553a6cf40b07093d1df283567f.html#ab140cb553a6cf40b07093d1df283567f">getSentence</a>();</div>
<div class="line"><a name="l00385"></a><span class="lineno">  385</span>&#160;        <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> belief = memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_aae366ea198c2340fef786120d5c2163b.html#aae366ea198c2340fef786120d5c2163b">getCurrentBelief</a>();</div>
<div class="line"><a name="l00386"></a><span class="lineno">  386</span>&#160;        <span class="keywordtype">boolean</span> conditionalTask = <a class="code" href="../../de/da5/classnars_1_1language_1_1Variable.html">Variable</a>.<a class="code" href="../../de/da5/classnars_1_1language_1_1Variable_a27d52c132400491e698146c554cd89ac.html#a27d52c132400491e698146c554cd89ac">hasSubstitute</a>(</div>
<div class="line"><a name="l00387"></a><span class="lineno">  387</span>&#160;                <a class="code" href="../../dc/d71/classnars_1_1io_1_1Symbols.html">Symbols</a>.<a class="code" href="../../dc/d71/classnars_1_1io_1_1Symbols_a60c92a89535a54f54a72e20a5969536d.html#a60c92a89535a54f54a72e20a5969536d">VAR_INDEPENDENT</a>, premise2, belief.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_ad1ded9a02cae3557948d05530cd4d37e.html#ad1ded9a02cae3557948d05530cd4d37e">getContent</a>());</div>
<div class="line"><a name="l00388"></a><span class="lineno">  388</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> commonComponent;</div>
<div class="line"><a name="l00389"></a><span class="lineno">  389</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> newComponent = null;</div>
<div class="line"><a name="l00390"></a><span class="lineno">  390</span>&#160;        <span class="keywordflow">if</span> (side == 0) {</div>
<div class="line"><a name="l00391"></a><span class="lineno">  391</span>&#160;            commonComponent = ((<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>) premise2).getSubject();</div>
<div class="line"><a name="l00392"></a><span class="lineno">  392</span>&#160;            newComponent = ((<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>) premise2).getPredicate();</div>
<div class="line"><a name="l00393"></a><span class="lineno">  393</span>&#160;        } <span class="keywordflow">else</span> <span class="keywordflow">if</span> (side == 1) {</div>
<div class="line"><a name="l00394"></a><span class="lineno">  394</span>&#160;            commonComponent = ((<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>) premise2).getPredicate();</div>
<div class="line"><a name="l00395"></a><span class="lineno">  395</span>&#160;            newComponent = ((<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>) premise2).getSubject();</div>
<div class="line"><a name="l00396"></a><span class="lineno">  396</span>&#160;        } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00397"></a><span class="lineno">  397</span>&#160;            commonComponent = premise2;</div>
<div class="line"><a name="l00398"></a><span class="lineno">  398</span>&#160;        }</div>
<div class="line"><a name="l00399"></a><span class="lineno">  399</span>&#160;        <a class="code" href="../../d6/d98/classnars_1_1language_1_1Conjunction.html">Conjunction</a> oldCondition = (<a class="code" href="../../d6/d98/classnars_1_1language_1_1Conjunction.html">Conjunction</a>) premise1.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_ace4f80751d303c613e467163913bebf5.html#ace4f80751d303c613e467163913bebf5">getSubject</a>();</div>
<div class="line"><a name="l00400"></a><span class="lineno">  400</span>&#160;        <span class="keywordtype">boolean</span> match = <a class="code" href="../../de/da5/classnars_1_1language_1_1Variable.html">Variable</a>.<a class="code" href="../../de/da5/classnars_1_1language_1_1Variable_a2770bbc76b3aac48f49a1c15aaedab1b.html#a2770bbc76b3aac48f49a1c15aaedab1b">unify</a>(<a class="code" href="../../dc/d71/classnars_1_1io_1_1Symbols.html">Symbols</a>.<a class="code" href="../../dc/d71/classnars_1_1io_1_1Symbols_a3c9984ce55deb7819945871ce1fa3a82.html#a3c9984ce55deb7819945871ce1fa3a82">VAR_DEPENDENT</a>,</div>
<div class="line"><a name="l00401"></a><span class="lineno">  401</span>&#160;                oldCondition.<a class="code" href="../../d0/dee/classnars_1_1language_1_1CompoundTerm_acedae916705e9fa1669391a7d728b840.html#acedae916705e9fa1669391a7d728b840">componentAt</a>(index), commonComponent, premise1,</div>
<div class="line"><a name="l00402"></a><span class="lineno">  402</span>&#160;                premise2);</div>
<div class="line"><a name="l00403"></a><span class="lineno">  403</span>&#160;        <span class="keywordflow">if</span> (!match &amp;&amp; (commonComponent.getClass() == oldCondition.getClass())) {</div>
<div class="line"><a name="l00404"></a><span class="lineno">  404</span>&#160;            match = <a class="code" href="../../de/da5/classnars_1_1language_1_1Variable.html">Variable</a>.<a class="code" href="../../de/da5/classnars_1_1language_1_1Variable_a2770bbc76b3aac48f49a1c15aaedab1b.html#a2770bbc76b3aac48f49a1c15aaedab1b">unify</a>(<a class="code" href="../../dc/d71/classnars_1_1io_1_1Symbols.html">Symbols</a>.<a class="code" href="../../dc/d71/classnars_1_1io_1_1Symbols_a3c9984ce55deb7819945871ce1fa3a82.html#a3c9984ce55deb7819945871ce1fa3a82">VAR_DEPENDENT</a>,</div>
<div class="line"><a name="l00405"></a><span class="lineno">  405</span>&#160;                    oldCondition.<a class="code" href="../../d0/dee/classnars_1_1language_1_1CompoundTerm_acedae916705e9fa1669391a7d728b840.html#acedae916705e9fa1669391a7d728b840">componentAt</a>(index),</div>
<div class="line"><a name="l00406"></a><span class="lineno">  406</span>&#160;                    ((<a class="code" href="../../d0/dee/classnars_1_1language_1_1CompoundTerm.html">CompoundTerm</a>) commonComponent).componentAt(index),</div>
<div class="line"><a name="l00407"></a><span class="lineno">  407</span>&#160;                    premise1, premise2);</div>
<div class="line"><a name="l00408"></a><span class="lineno">  408</span>&#160;        }</div>
<div class="line"><a name="l00409"></a><span class="lineno">  409</span>&#160;        <span class="keywordflow">if</span> (!match) {</div>
<div class="line"><a name="l00410"></a><span class="lineno">  410</span>&#160;            <span class="keywordflow">return</span>;</div>
<div class="line"><a name="l00411"></a><span class="lineno">  411</span>&#160;        }</div>
<div class="line"><a name="l00412"></a><span class="lineno">  412</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> newCondition;</div>
<div class="line"><a name="l00413"></a><span class="lineno">  413</span>&#160;        <span class="keywordflow">if</span> (oldCondition.<a class="code" href="../../d8/db8/classnars_1_1language_1_1Term_ad85f45a7858737445d5158801774ff5f.html#ad85f45a7858737445d5158801774ff5f">equals</a>(commonComponent)) {</div>
<div class="line"><a name="l00414"></a><span class="lineno">  414</span>&#160;            newCondition = null;</div>
<div class="line"><a name="l00415"></a><span class="lineno">  415</span>&#160;        } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00416"></a><span class="lineno">  416</span>&#160;            newCondition = <a class="code" href="../../d0/dee/classnars_1_1language_1_1CompoundTerm.html">CompoundTerm</a>.<a class="code" href="../../d0/dee/classnars_1_1language_1_1CompoundTerm_a623c88183d85bd42464640937ea8ccb5.html#a623c88183d85bd42464640937ea8ccb5">setComponent</a>(oldCondition, index,</div>
<div class="line"><a name="l00417"></a><span class="lineno">  417</span>&#160;                    newComponent, memory);</div>
<div class="line"><a name="l00418"></a><span class="lineno">  418</span>&#160;        }</div>
<div class="line"><a name="l00419"></a><span class="lineno">  419</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> content;</div>
<div class="line"><a name="l00420"></a><span class="lineno">  420</span>&#160;        <span class="keywordflow">if</span> (newCondition != null) {</div>
<div class="line"><a name="l00421"></a><span class="lineno">  421</span>&#160;            content = <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_a4e4c29fc305a6741da88ce55fbf11e4a.html#a4e4c29fc305a6741da88ce55fbf11e4a">make</a>(premise1, newCondition,</div>
<div class="line"><a name="l00422"></a><span class="lineno">  422</span>&#160;                    premise1.getPredicate(), memory);</div>
<div class="line"><a name="l00423"></a><span class="lineno">  423</span>&#160;        } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00424"></a><span class="lineno">  424</span>&#160;            content = premise1.getPredicate();</div>
<div class="line"><a name="l00425"></a><span class="lineno">  425</span>&#160;        }</div>
<div class="line"><a name="l00426"></a><span class="lineno">  426</span>&#160;        <span class="keywordflow">if</span> (content == null) {</div>
<div class="line"><a name="l00427"></a><span class="lineno">  427</span>&#160;            <span class="keywordflow">return</span>;</div>
<div class="line"><a name="l00428"></a><span class="lineno">  428</span>&#160;        }</div>
<div class="line"><a name="l00429"></a><span class="lineno">  429</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> truth1 = taskSentence.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>();</div>
<div class="line"><a name="l00430"></a><span class="lineno">  430</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> truth2 = belief.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>();</div>
<div class="line"><a name="l00431"></a><span class="lineno">  431</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> truth = null;</div>
<div class="line"><a name="l00432"></a><span class="lineno">  432</span>&#160;        <a class="code" href="../../db/d8e/classnars_1_1entity_1_1BudgetValue.html">BudgetValue</a> budget;</div>
<div class="line"><a name="l00433"></a><span class="lineno">  433</span>&#160;        <span class="keywordflow">if</span> (taskSentence.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_acb98b40c8990dbe5e15061f0759c60ee.html#acb98b40c8990dbe5e15061f0759c60ee">isQuestion</a>()) {</div>
<div class="line"><a name="l00434"></a><span class="lineno">  434</span>&#160;            budget = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_a90343f7d4de3a6ffcd57493b7a09376f.html#a90343f7d4de3a6ffcd57493b7a09376f">backwardWeak</a>(truth2, memory);</div>
<div class="line"><a name="l00435"></a><span class="lineno">  435</span>&#160;        } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00436"></a><span class="lineno">  436</span>&#160;            <span class="keywordflow">if</span> (conditionalTask) {</div>
<div class="line"><a name="l00437"></a><span class="lineno">  437</span>&#160;                truth = <a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions.html">TruthFunctions</a>.<a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_a0eded294e31894aad09eb976587a20d3.html#a0eded294e31894aad09eb976587a20d3">comparison</a>(truth1, truth2);</div>
<div class="line"><a name="l00438"></a><span class="lineno">  438</span>&#160;            } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00439"></a><span class="lineno">  439</span>&#160;                truth = <a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions.html">TruthFunctions</a>.<a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_a93ca820557fc8d18ef741bd33501126f.html#a93ca820557fc8d18ef741bd33501126f">analogy</a>(truth1, truth2);</div>
<div class="line"><a name="l00440"></a><span class="lineno">  440</span>&#160;            }</div>
<div class="line"><a name="l00441"></a><span class="lineno">  441</span>&#160;            budget = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_ac3df7e788b7a6e2b348d2ae7da7936c5.html#ac3df7e788b7a6e2b348d2ae7da7936c5">forward</a>(truth, memory);</div>
<div class="line"><a name="l00442"></a><span class="lineno">  442</span>&#160;        }</div>
<div class="line"><a name="l00443"></a><span class="lineno">  443</span>&#160;        memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_a077b38e451ff6e4217bdc2ff0bb08e70.html#a077b38e451ff6e4217bdc2ff0bb08e70">doublePremiseTask</a>(content, truth, budget);</div>
<div class="line"><a name="l00444"></a><span class="lineno">  444</span>&#160;    }</div>
<div class="line"><a name="l00445"></a><span class="lineno">  445</span>&#160;</div>
<div class="line"><a name="l00461"></a><span class="lineno"><a class="line" href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules_a188ed61b1cef0b9e8af45d5dc372da31.html#a188ed61b1cef0b9e8af45d5dc372da31">  461</a></span>&#160;    <span class="keyword">static</span> <span class="keywordtype">boolean</span> <a class="code" href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules_a188ed61b1cef0b9e8af45d5dc372da31.html#a188ed61b1cef0b9e8af45d5dc372da31">conditionalAbd</a>(<a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> cond1, <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> cond2, <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a> st1,</div>
<div class="line"><a name="l00462"></a><span class="lineno">  462</span>&#160;            <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a> st2, <a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory.html">Memory</a> memory) {</div>
<div class="line"><a name="l00463"></a><span class="lineno">  463</span>&#160;        <span class="keywordflow">if</span> (!(st1 instanceof <a class="code" href="../../da/db6/classnars_1_1language_1_1Implication.html">Implication</a>) || !(st2 instanceof Implication)) {</div>
<div class="line"><a name="l00464"></a><span class="lineno">  464</span>&#160;            <span class="keywordflow">return</span> <span class="keyword">false</span>;</div>
<div class="line"><a name="l00465"></a><span class="lineno">  465</span>&#160;        }</div>
<div class="line"><a name="l00466"></a><span class="lineno">  466</span>&#160;        <span class="keywordflow">if</span> (!(cond1 instanceof <a class="code" href="../../d6/d98/classnars_1_1language_1_1Conjunction.html">Conjunction</a>) &amp;&amp; !(cond2 instanceof Conjunction)) {</div>
<div class="line"><a name="l00467"></a><span class="lineno">  467</span>&#160;            <span class="keywordflow">return</span> <span class="keyword">false</span>;</div>
<div class="line"><a name="l00468"></a><span class="lineno">  468</span>&#160;        }</div>
<div class="line"><a name="l00469"></a><span class="lineno">  469</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> term1 = null;</div>
<div class="line"><a name="l00470"></a><span class="lineno">  470</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> term2 = null;</div>
<div class="line"><a name="l00471"></a><span class="lineno">  471</span>&#160;        <span class="keywordflow">if</span> (cond1 instanceof Conjunction) {</div>
<div class="line"><a name="l00472"></a><span class="lineno">  472</span>&#160;            term1 = <a class="code" href="../../d0/dee/classnars_1_1language_1_1CompoundTerm.html">CompoundTerm</a>.<a class="code" href="../../d0/dee/classnars_1_1language_1_1CompoundTerm_a09c88a408c16b985b0db4bc602a170aa.html#a09c88a408c16b985b0db4bc602a170aa">reduceComponents</a>((Conjunction) cond1, cond2,</div>
<div class="line"><a name="l00473"></a><span class="lineno">  473</span>&#160;                    memory);</div>
<div class="line"><a name="l00474"></a><span class="lineno">  474</span>&#160;        }</div>
<div class="line"><a name="l00475"></a><span class="lineno">  475</span>&#160;        <span class="keywordflow">if</span> (cond2 instanceof Conjunction) {</div>
<div class="line"><a name="l00476"></a><span class="lineno">  476</span>&#160;            term2 = <a class="code" href="../../d0/dee/classnars_1_1language_1_1CompoundTerm.html">CompoundTerm</a>.<a class="code" href="../../d0/dee/classnars_1_1language_1_1CompoundTerm_a09c88a408c16b985b0db4bc602a170aa.html#a09c88a408c16b985b0db4bc602a170aa">reduceComponents</a>((Conjunction) cond2, cond1,</div>
<div class="line"><a name="l00477"></a><span class="lineno">  477</span>&#160;                    memory);</div>
<div class="line"><a name="l00478"></a><span class="lineno">  478</span>&#160;        }</div>
<div class="line"><a name="l00479"></a><span class="lineno">  479</span>&#160;        <span class="keywordflow">if</span> ((term1 == null) &amp;&amp; (term2 == null)) {</div>
<div class="line"><a name="l00480"></a><span class="lineno">  480</span>&#160;            <span class="keywordflow">return</span> <span class="keyword">false</span>;</div>
<div class="line"><a name="l00481"></a><span class="lineno">  481</span>&#160;        }</div>
<div class="line"><a name="l00482"></a><span class="lineno">  482</span>&#160;        <a class="code" href="../../dc/ddc/classnars_1_1entity_1_1Task.html">Task</a> task = memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_a26eda4f00b333b706b4e3d069fdf1508.html#a26eda4f00b333b706b4e3d069fdf1508">getCurrentTask</a>();</div>
<div class="line"><a name="l00483"></a><span class="lineno">  483</span>&#160;        <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> sentence = task.<a class="code" href="../../dc/ddc/classnars_1_1entity_1_1Task_ab140cb553a6cf40b07093d1df283567f.html#ab140cb553a6cf40b07093d1df283567f">getSentence</a>();</div>
<div class="line"><a name="l00484"></a><span class="lineno">  484</span>&#160;        <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> belief = memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_aae366ea198c2340fef786120d5c2163b.html#aae366ea198c2340fef786120d5c2163b">getCurrentBelief</a>();</div>
<div class="line"><a name="l00485"></a><span class="lineno">  485</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> value1 = sentence.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>();</div>
<div class="line"><a name="l00486"></a><span class="lineno">  486</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> value2 = belief.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>();</div>
<div class="line"><a name="l00487"></a><span class="lineno">  487</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> content;</div>
<div class="line"><a name="l00488"></a><span class="lineno">  488</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> truth = null;</div>
<div class="line"><a name="l00489"></a><span class="lineno">  489</span>&#160;        <a class="code" href="../../db/d8e/classnars_1_1entity_1_1BudgetValue.html">BudgetValue</a> budget;</div>
<div class="line"><a name="l00490"></a><span class="lineno">  490</span>&#160;        <span class="keywordflow">if</span> (term1 != null) {</div>
<div class="line"><a name="l00491"></a><span class="lineno">  491</span>&#160;            <span class="keywordflow">if</span> (term2 != null) {</div>
<div class="line"><a name="l00492"></a><span class="lineno">  492</span>&#160;                content = <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_a4e4c29fc305a6741da88ce55fbf11e4a.html#a4e4c29fc305a6741da88ce55fbf11e4a">make</a>(st2, term2, term1, memory);</div>
<div class="line"><a name="l00493"></a><span class="lineno">  493</span>&#160;            } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00494"></a><span class="lineno">  494</span>&#160;                content = term1;</div>
<div class="line"><a name="l00495"></a><span class="lineno">  495</span>&#160;            }</div>
<div class="line"><a name="l00496"></a><span class="lineno">  496</span>&#160;            <span class="keywordflow">if</span> (sentence.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_acb98b40c8990dbe5e15061f0759c60ee.html#acb98b40c8990dbe5e15061f0759c60ee">isQuestion</a>()) {</div>
<div class="line"><a name="l00497"></a><span class="lineno">  497</span>&#160;                budget = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_a90343f7d4de3a6ffcd57493b7a09376f.html#a90343f7d4de3a6ffcd57493b7a09376f">backwardWeak</a>(value2, memory);</div>
<div class="line"><a name="l00498"></a><span class="lineno">  498</span>&#160;            } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00499"></a><span class="lineno">  499</span>&#160;                truth = <a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions.html">TruthFunctions</a>.<a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_ab001ba72b5926188d21dd48a5eaaeb8b.html#ab001ba72b5926188d21dd48a5eaaeb8b">abduction</a>(value2, value1);</div>
<div class="line"><a name="l00500"></a><span class="lineno">  500</span>&#160;                budget = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_ac3df7e788b7a6e2b348d2ae7da7936c5.html#ac3df7e788b7a6e2b348d2ae7da7936c5">forward</a>(truth, memory);</div>
<div class="line"><a name="l00501"></a><span class="lineno">  501</span>&#160;            }</div>
<div class="line"><a name="l00502"></a><span class="lineno">  502</span>&#160;            memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_a077b38e451ff6e4217bdc2ff0bb08e70.html#a077b38e451ff6e4217bdc2ff0bb08e70">doublePremiseTask</a>(content, truth, budget);</div>
<div class="line"><a name="l00503"></a><span class="lineno">  503</span>&#160;        }</div>
<div class="line"><a name="l00504"></a><span class="lineno">  504</span>&#160;        <span class="keywordflow">if</span> (term2 != null) {</div>
<div class="line"><a name="l00505"></a><span class="lineno">  505</span>&#160;            <span class="keywordflow">if</span> (term1 != null) {</div>
<div class="line"><a name="l00506"></a><span class="lineno">  506</span>&#160;                content = <a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement.html">Statement</a>.<a class="code" href="../../d1/d5e/classnars_1_1language_1_1Statement_a4e4c29fc305a6741da88ce55fbf11e4a.html#a4e4c29fc305a6741da88ce55fbf11e4a">make</a>(st1, term1, term2, memory);</div>
<div class="line"><a name="l00507"></a><span class="lineno">  507</span>&#160;            } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00508"></a><span class="lineno">  508</span>&#160;                content = term2;</div>
<div class="line"><a name="l00509"></a><span class="lineno">  509</span>&#160;            }</div>
<div class="line"><a name="l00510"></a><span class="lineno">  510</span>&#160;            <span class="keywordflow">if</span> (sentence.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_acb98b40c8990dbe5e15061f0759c60ee.html#acb98b40c8990dbe5e15061f0759c60ee">isQuestion</a>()) {</div>
<div class="line"><a name="l00511"></a><span class="lineno">  511</span>&#160;                budget = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_a90343f7d4de3a6ffcd57493b7a09376f.html#a90343f7d4de3a6ffcd57493b7a09376f">backwardWeak</a>(value2, memory);</div>
<div class="line"><a name="l00512"></a><span class="lineno">  512</span>&#160;            } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00513"></a><span class="lineno">  513</span>&#160;                truth = <a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions.html">TruthFunctions</a>.<a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_ab001ba72b5926188d21dd48a5eaaeb8b.html#ab001ba72b5926188d21dd48a5eaaeb8b">abduction</a>(value1, value2);</div>
<div class="line"><a name="l00514"></a><span class="lineno">  514</span>&#160;                budget = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_ac3df7e788b7a6e2b348d2ae7da7936c5.html#ac3df7e788b7a6e2b348d2ae7da7936c5">forward</a>(truth, memory);</div>
<div class="line"><a name="l00515"></a><span class="lineno">  515</span>&#160;            }</div>
<div class="line"><a name="l00516"></a><span class="lineno">  516</span>&#160;            memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_a077b38e451ff6e4217bdc2ff0bb08e70.html#a077b38e451ff6e4217bdc2ff0bb08e70">doublePremiseTask</a>(content, truth, budget);</div>
<div class="line"><a name="l00517"></a><span class="lineno">  517</span>&#160;        }</div>
<div class="line"><a name="l00518"></a><span class="lineno">  518</span>&#160;        <span class="keywordflow">return</span> <span class="keyword">true</span>;</div>
<div class="line"><a name="l00519"></a><span class="lineno">  519</span>&#160;    }</div>
<div class="line"><a name="l00520"></a><span class="lineno">  520</span>&#160;</div>
<div class="line"><a name="l00533"></a><span class="lineno"><a class="line" href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules_a315c474733bb01f6f01e579221b417d4.html#a315c474733bb01f6f01e579221b417d4">  533</a></span>&#160;    <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules_a315c474733bb01f6f01e579221b417d4.html#a315c474733bb01f6f01e579221b417d4">elimiVarDep</a>(<a class="code" href="../../d0/dee/classnars_1_1language_1_1CompoundTerm.html">CompoundTerm</a> compound, <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> component,</div>
<div class="line"><a name="l00534"></a><span class="lineno">  534</span>&#160;            <span class="keywordtype">boolean</span> compoundTask, <a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory.html">Memory</a> memory) {</div>
<div class="line"><a name="l00535"></a><span class="lineno">  535</span>&#160;        <a class="code" href="../../d8/db8/classnars_1_1language_1_1Term.html">Term</a> content = <a class="code" href="../../d0/dee/classnars_1_1language_1_1CompoundTerm.html">CompoundTerm</a>.<a class="code" href="../../d0/dee/classnars_1_1language_1_1CompoundTerm_a09c88a408c16b985b0db4bc602a170aa.html#a09c88a408c16b985b0db4bc602a170aa">reduceComponents</a>(compound, component,</div>
<div class="line"><a name="l00536"></a><span class="lineno">  536</span>&#160;                memory);</div>
<div class="line"><a name="l00537"></a><span class="lineno">  537</span>&#160;        <a class="code" href="../../dc/ddc/classnars_1_1entity_1_1Task.html">Task</a> task = memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_a26eda4f00b333b706b4e3d069fdf1508.html#a26eda4f00b333b706b4e3d069fdf1508">getCurrentTask</a>();</div>
<div class="line"><a name="l00538"></a><span class="lineno">  538</span>&#160;        <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> sentence = task.<a class="code" href="../../dc/ddc/classnars_1_1entity_1_1Task_ab140cb553a6cf40b07093d1df283567f.html#ab140cb553a6cf40b07093d1df283567f">getSentence</a>();</div>
<div class="line"><a name="l00539"></a><span class="lineno">  539</span>&#160;        <a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">Sentence</a> belief = memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_aae366ea198c2340fef786120d5c2163b.html#aae366ea198c2340fef786120d5c2163b">getCurrentBelief</a>();</div>
<div class="line"><a name="l00540"></a><span class="lineno">  540</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> v1 = sentence.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>();</div>
<div class="line"><a name="l00541"></a><span class="lineno">  541</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> v2 = belief.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">getTruth</a>();</div>
<div class="line"><a name="l00542"></a><span class="lineno">  542</span>&#160;        <a class="code" href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">TruthValue</a> truth = null;</div>
<div class="line"><a name="l00543"></a><span class="lineno">  543</span>&#160;        <a class="code" href="../../db/d8e/classnars_1_1entity_1_1BudgetValue.html">BudgetValue</a> budget;</div>
<div class="line"><a name="l00544"></a><span class="lineno">  544</span>&#160;        <span class="keywordflow">if</span> (sentence.<a class="code" href="../../d6/d25/classnars_1_1entity_1_1Sentence_acb98b40c8990dbe5e15061f0759c60ee.html#acb98b40c8990dbe5e15061f0759c60ee">isQuestion</a>()) {</div>
<div class="line"><a name="l00545"></a><span class="lineno">  545</span>&#160;            budget = (compoundTask</div>
<div class="line"><a name="l00546"></a><span class="lineno">  546</span>&#160;                    ? <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_a62ee0953b7880e2547458aa575e14161.html#a62ee0953b7880e2547458aa575e14161">backward</a>(v2, memory)</div>
<div class="line"><a name="l00547"></a><span class="lineno">  547</span>&#160;                    : <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_a90343f7d4de3a6ffcd57493b7a09376f.html#a90343f7d4de3a6ffcd57493b7a09376f">backwardWeak</a>(v2, memory));</div>
<div class="line"><a name="l00548"></a><span class="lineno">  548</span>&#160;        } <span class="keywordflow">else</span> {</div>
<div class="line"><a name="l00549"></a><span class="lineno">  549</span>&#160;            truth = (compoundTask</div>
<div class="line"><a name="l00550"></a><span class="lineno">  550</span>&#160;                    ? <a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions.html">TruthFunctions</a>.<a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_ad7f4353395335ad37f76d83ea8aae8e2.html#ad7f4353395335ad37f76d83ea8aae8e2">anonymousAnalogy</a>(v1, v2)</div>
<div class="line"><a name="l00551"></a><span class="lineno">  551</span>&#160;                    : <a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions.html">TruthFunctions</a>.<a class="code" href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_ad7f4353395335ad37f76d83ea8aae8e2.html#ad7f4353395335ad37f76d83ea8aae8e2">anonymousAnalogy</a>(v2, v1));</div>
<div class="line"><a name="l00552"></a><span class="lineno">  552</span>&#160;            budget = <a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">BudgetFunctions</a>.<a class="code" href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_a74ebb7970c0561c3407df43a68bbfe84.html#a74ebb7970c0561c3407df43a68bbfe84">compoundForward</a>(truth, content, memory);</div>
<div class="line"><a name="l00553"></a><span class="lineno">  553</span>&#160;        }</div>
<div class="line"><a name="l00554"></a><span class="lineno">  554</span>&#160;        memory.<a class="code" href="../../d8/df4/classnars_1_1storage_1_1Memory_a077b38e451ff6e4217bdc2ff0bb08e70.html#a077b38e451ff6e4217bdc2ff0bb08e70">doublePremiseTask</a>(content, truth, budget);</div>
<div class="line"><a name="l00555"></a><span class="lineno">  555</span>&#160;    }</div>
<div class="line"><a name="l00556"></a><span class="lineno">  556</span>&#160;}</div>
<div class="ttc" id="classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9_html_a9f69b4fef64c81abad21404946cd41f9"><div class="ttname"><a href="../../d6/d25/classnars_1_1entity_1_1Sentence_a9f69b4fef64c81abad21404946cd41f9.html#a9f69b4fef64c81abad21404946cd41f9">nars.entity.Sentence.getTruth</a></div><div class="ttdeci">TruthValue getTruth()</div><div class="ttdoc">Get the truth value of the sentence. </div><div class="ttdef"><b>Definition:</b> <a href="../../da/d1c/Sentence_8java_source.html#l00165">Sentence.java:165</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1TruthFunctions_ab001ba72b5926188d21dd48a5eaaeb8b_html_ab001ba72b5926188d21dd48a5eaaeb8b"><div class="ttname"><a href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_ab001ba72b5926188d21dd48a5eaaeb8b.html#ab001ba72b5926188d21dd48a5eaaeb8b">nars.inference.TruthFunctions.abduction</a></div><div class="ttdeci">static TruthValue abduction(TruthValue v1, TruthValue v2)</div><div class="ttdoc">{<S ==> M>, </div><div class="ttdef"><b>Definition:</b> <a href="../../df/d29/TruthFunctions_8java_source.html#l00183">TruthFunctions.java:183</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Conjunction_html"><div class="ttname"><a href="../../d6/d98/classnars_1_1language_1_1Conjunction.html">nars.language.Conjunction</a></div><div class="ttdoc">Conjunction of statements. </div><div class="ttdef"><b>Definition:</b> <a href="../../d6/d2f/Conjunction_8java_source.html#l00031">Conjunction.java:31</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1BudgetFunctions_a62ee0953b7880e2547458aa575e14161_html_a62ee0953b7880e2547458aa575e14161"><div class="ttname"><a href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_a62ee0953b7880e2547458aa575e14161.html#a62ee0953b7880e2547458aa575e14161">nars.inference.BudgetFunctions.backward</a></div><div class="ttdeci">static BudgetValue backward(TruthValue truth, Memory memory)</div><div class="ttdoc">Backward inference result and adjustment, stronger case. </div><div class="ttdef"><b>Definition:</b> <a href="../../de/d4e/BudgetFunctions_8java_source.html#l00261">BudgetFunctions.java:261</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Statement_ababe6155e2f78e769f76493317e118e0_html_ababe6155e2f78e769f76493317e118e0"><div class="ttname"><a href="../../d1/d5e/classnars_1_1language_1_1Statement_ababe6155e2f78e769f76493317e118e0.html#ababe6155e2f78e769f76493317e118e0">nars.language.Statement.getPredicate</a></div><div class="ttdeci">Term getPredicate()</div><div class="ttdoc">Return the second component of the statement. </div><div class="ttdef"><b>Definition:</b> <a href="../../d2/d44/Statement_8java_source.html#l00237">Statement.java:237</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1CompoundTerm_a9778c35f9b602bee6ccac6a06809e546_html_a9778c35f9b602bee6ccac6a06809e546"><div class="ttname"><a href="../../d0/dee/classnars_1_1language_1_1CompoundTerm_a9778c35f9b602bee6ccac6a06809e546.html#a9778c35f9b602bee6ccac6a06809e546">nars.language.CompoundTerm.getComponents</a></div><div class="ttdeci">List&lt; Term &gt; getComponents()</div><div class="ttdoc">Get the component list. </div><div class="ttdef"><b>Definition:</b> <a href="../../d5/d0e/CompoundTerm_8java_source.html#l00364">CompoundTerm.java:364</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Statement_a5cabf7120a4c6a0e94d18e436cbdc916_html_a5cabf7120a4c6a0e94d18e436cbdc916"><div class="ttname"><a href="../../d1/d5e/classnars_1_1language_1_1Statement_a5cabf7120a4c6a0e94d18e436cbdc916.html#a5cabf7120a4c6a0e94d18e436cbdc916">nars.language.Statement.makeSym</a></div><div class="ttdeci">static Statement makeSym(Statement statement, Term subj, Term pred, Memory memory)</div><div class="ttdoc">Make a symmetric Statement from given components and temporal information, called by the rules...</div><div class="ttdef"><b>Definition:</b> <a href="../../d2/d44/Statement_8java_source.html#l00128">Statement.java:128</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1TruthFunctions_html"><div class="ttname"><a href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions.html">nars.inference.TruthFunctions</a></div><div class="ttdoc">All truth-value (and desire-value) functions used in inference rules. </div><div class="ttdef"><b>Definition:</b> <a href="../../df/d29/TruthFunctions_8java_source.html#l00028">TruthFunctions.java:28</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1BudgetFunctions_a90343f7d4de3a6ffcd57493b7a09376f_html_a90343f7d4de3a6ffcd57493b7a09376f"><div class="ttname"><a href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_a90343f7d4de3a6ffcd57493b7a09376f.html#a90343f7d4de3a6ffcd57493b7a09376f">nars.inference.BudgetFunctions.backwardWeak</a></div><div class="ttdeci">static BudgetValue backwardWeak(TruthValue truth, Memory memory)</div><div class="ttdoc">Backward inference result and adjustment, weaker case. </div><div class="ttdef"><b>Definition:</b> <a href="../../de/d4e/BudgetFunctions_8java_source.html#l00274">BudgetFunctions.java:274</a></div></div>
<div class="ttc" id="namespacenars_1_1entity_html"><div class="ttname"><a href="../../db/dec/namespacenars_1_1entity.html">nars.entity</a></div><div class="ttdef"><b>Definition:</b> <a href="../../d8/d59/BudgetValue_8java_source.html#l00021">BudgetValue.java:21</a></div></div>
<div class="ttc" id="namespacenars_1_1io_html"><div class="ttname"><a href="../../db/d64/namespacenars_1_1io.html">nars.io</a></div><div class="ttdef"><b>Definition:</b> <a href="../../d3/d26/ExperienceReader_8java_source.html#l00021">ExperienceReader.java:21</a></div></div>
<div class="ttc" id="classnars_1_1storage_1_1Memory_html"><div class="ttname"><a href="../../d8/df4/classnars_1_1storage_1_1Memory.html">nars.storage.Memory</a></div><div class="ttdoc">The memory of the system. </div><div class="ttdef"><b>Definition:</b> <a href="../../db/d0c/Memory_8java_source.html#l00051">Memory.java:51</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1TruthFunctions_a54676ae3de8c6ef712566837b99d08a1_html_a54676ae3de8c6ef712566837b99d08a1"><div class="ttname"><a href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_a54676ae3de8c6ef712566837b99d08a1.html#a54676ae3de8c6ef712566837b99d08a1">nars.inference.TruthFunctions.exemplification</a></div><div class="ttdeci">static TruthValue exemplification(TruthValue v1, TruthValue v2)</div><div class="ttdoc">{<M ==> S>, </div><div class="ttdef"><b>Definition:</b> <a href="../../df/d29/TruthFunctions_8java_source.html#l00236">TruthFunctions.java:236</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1SyllogisticRules_html"><div class="ttname"><a href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules.html">nars.inference.SyllogisticRules</a></div><div class="ttdoc">Syllogisms: Inference rules based on the transitivity of the relation. </div><div class="ttdef"><b>Definition:</b> <a href="../../d4/d6b/SyllogisticRules_8java_source.html#l00031">SyllogisticRules.java:31</a></div></div>
<div class="ttc" id="classnars_1_1storage_1_1Memory_a26eda4f00b333b706b4e3d069fdf1508_html_a26eda4f00b333b706b4e3d069fdf1508"><div class="ttname"><a href="../../d8/df4/classnars_1_1storage_1_1Memory_a26eda4f00b333b706b4e3d069fdf1508.html#a26eda4f00b333b706b4e3d069fdf1508">nars.storage.Memory.getCurrentTask</a></div><div class="ttdeci">Task getCurrentTask()</div><div class="ttdoc">The selected Task. </div><div class="ttdef"><b>Definition:</b> <a href="../../db/d0c/Memory_8java_source.html#l00625">Memory.java:625</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1TruthFunctions_af0cd0f846c8a7e500840b517ab006b94_html_af0cd0f846c8a7e500840b517ab006b94"><div class="ttname"><a href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_af0cd0f846c8a7e500840b517ab006b94.html#af0cd0f846c8a7e500840b517ab006b94">nars.inference.TruthFunctions.deduction</a></div><div class="ttdeci">static TruthValue deduction(TruthValue v1, TruthValue v2)</div><div class="ttdoc">{<S ==> M>, <M ==> P>} |- <S ==> P> </div><div class="ttdef"><b>Definition:</b> <a href="../../df/d29/TruthFunctions_8java_source.html#l00108">TruthFunctions.java:108</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1TruthFunctions_aed67308b830f5b1780c075f2736f3ad0_html_aed67308b830f5b1780c075f2736f3ad0"><div class="ttname"><a href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_aed67308b830f5b1780c075f2736f3ad0.html#aed67308b830f5b1780c075f2736f3ad0">nars.inference.TruthFunctions.induction</a></div><div class="ttdeci">static TruthValue induction(TruthValue v1, TruthValue v2)</div><div class="ttdoc">{<M ==> S>, <M ==> P>} |- <S ==> P> </div><div class="ttdef"><b>Definition:</b> <a href="../../df/d29/TruthFunctions_8java_source.html#l00221">TruthFunctions.java:221</a></div></div>
<div class="ttc" id="classnars_1_1entity_1_1Task_html"><div class="ttname"><a href="../../dc/ddc/classnars_1_1entity_1_1Task.html">nars.entity.Task</a></div><div class="ttdoc">A task to be processed, consists of a Sentence and a BudgetValue. </div><div class="ttdef"><b>Definition:</b> <a href="../../d6/d10/Task_8java_source.html#l00035">Task.java:35</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Statement_a4e4c29fc305a6741da88ce55fbf11e4a_html_a4e4c29fc305a6741da88ce55fbf11e4a"><div class="ttname"><a href="../../d1/d5e/classnars_1_1language_1_1Statement_a4e4c29fc305a6741da88ce55fbf11e4a.html#a4e4c29fc305a6741da88ce55fbf11e4a">nars.language.Statement.make</a></div><div class="ttdeci">static Statement make(String relation, Term subject, Term predicate, Memory memory)</div><div class="ttdoc">Make a Statement from String, called by StringParser. </div><div class="ttdef"><b>Definition:</b> <a href="../../d2/d44/Statement_8java_source.html#l00068">Statement.java:68</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Statement_html"><div class="ttname"><a href="../../d1/d5e/classnars_1_1language_1_1Statement.html">nars.language.Statement</a></div><div class="ttdoc">A statement is a compound term, consisting of a subject, a predicate, and a relation symbol in betwee...</div><div class="ttdef"><b>Definition:</b> <a href="../../d2/d44/Statement_8java_source.html#l00033">Statement.java:33</a></div></div>
<div class="ttc" id="classnars_1_1entity_1_1Task_ab140cb553a6cf40b07093d1df283567f_html_ab140cb553a6cf40b07093d1df283567f"><div class="ttname"><a href="../../dc/ddc/classnars_1_1entity_1_1Task_ab140cb553a6cf40b07093d1df283567f.html#ab140cb553a6cf40b07093d1df283567f">nars.entity.Task.getSentence</a></div><div class="ttdeci">Sentence getSentence()</div><div class="ttdoc">Get the sentence. </div><div class="ttdef"><b>Definition:</b> <a href="../../d6/d10/Task_8java_source.html#l00099">Task.java:99</a></div></div>
<div class="ttc" id="classnars_1_1io_1_1Symbols_html"><div class="ttname"><a href="../../dc/d71/classnars_1_1io_1_1Symbols.html">nars.io.Symbols</a></div><div class="ttdoc">The ASCII symbols used in I/O. </div><div class="ttdef"><b>Definition:</b> <a href="../../d5/da0/Symbols_8java_source.html#l00026">Symbols.java:26</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1CompoundTerm_a09c88a408c16b985b0db4bc602a170aa_html_a09c88a408c16b985b0db4bc602a170aa"><div class="ttname"><a href="../../d0/dee/classnars_1_1language_1_1CompoundTerm_a09c88a408c16b985b0db4bc602a170aa.html#a09c88a408c16b985b0db4bc602a170aa">nars.language.CompoundTerm.reduceComponents</a></div><div class="ttdeci">static Term reduceComponents(CompoundTerm t1, Term t2, Memory memory)</div><div class="ttdoc">Try to remove a component from a compound. </div><div class="ttdef"><b>Definition:</b> <a href="../../d5/d0e/CompoundTerm_8java_source.html#l00457">CompoundTerm.java:457</a></div></div>
<div class="ttc" id="classnars_1_1entity_1_1Sentence_ad1ded9a02cae3557948d05530cd4d37e_html_ad1ded9a02cae3557948d05530cd4d37e"><div class="ttname"><a href="../../d6/d25/classnars_1_1entity_1_1Sentence_ad1ded9a02cae3557948d05530cd4d37e.html#ad1ded9a02cae3557948d05530cd4d37e">nars.entity.Sentence.getContent</a></div><div class="ttdeci">Term getContent()</div><div class="ttdoc">Get the content of the sentence. </div><div class="ttdef"><b>Definition:</b> <a href="../../da/d1c/Sentence_8java_source.html#l00133">Sentence.java:133</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1SyllogisticRules_a5724b3ed7e885c29110acceac0d677d5_html_a5724b3ed7e885c29110acceac0d677d5"><div class="ttname"><a href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules_a5724b3ed7e885c29110acceac0d677d5.html#a5724b3ed7e885c29110acceac0d677d5">nars.inference.SyllogisticRules.dedExe</a></div><div class="ttdeci">static void dedExe(Term term1, Term term2, Sentence sentence, Sentence belief, Memory memory)</div><div class="ttdef"><b>Definition:</b> <a href="../../d4/d6b/SyllogisticRules_8java_source.html#l00053">SyllogisticRules.java:53</a></div></div>
<div class="ttc" id="namespacenars_1_1storage_html"><div class="ttname"><a href="../../de/ddc/namespacenars_1_1storage.html">nars.storage</a></div><div class="ttdef"><b>Definition:</b> <a href="../../d6/dce/Bag_8java_source.html#l00021">Bag.java:21</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1BudgetFunctions_a74ebb7970c0561c3407df43a68bbfe84_html_a74ebb7970c0561c3407df43a68bbfe84"><div class="ttname"><a href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_a74ebb7970c0561c3407df43a68bbfe84.html#a74ebb7970c0561c3407df43a68bbfe84">nars.inference.BudgetFunctions.compoundForward</a></div><div class="ttdeci">static BudgetValue compoundForward(TruthValue truth, Term content, Memory memory)</div><div class="ttdoc">Forward inference with CompoundTerm conclusion. </div><div class="ttdef"><b>Definition:</b> <a href="../../de/d4e/BudgetFunctions_8java_source.html#l00290">BudgetFunctions.java:290</a></div></div>
<div class="ttc" id="classnars_1_1entity_1_1Sentence_acb98b40c8990dbe5e15061f0759c60ee_html_acb98b40c8990dbe5e15061f0759c60ee"><div class="ttname"><a href="../../d6/d25/classnars_1_1entity_1_1Sentence_acb98b40c8990dbe5e15061f0759c60ee.html#acb98b40c8990dbe5e15061f0759c60ee">nars.entity.Sentence.isQuestion</a></div><div class="ttdeci">boolean isQuestion()</div><div class="ttdoc">Distinguish Question from Quest ("instanceof Question" doesn&#39;t work) </div><div class="ttdef"><b>Definition:</b> <a href="../../da/d1c/Sentence_8java_source.html#l00189">Sentence.java:189</a></div></div>
<div class="ttc" id="namespacenars_html"><div class="ttname"><a href="../../d7/d81/namespacenars.html">nars</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1SyllogisticRules_a188ed61b1cef0b9e8af45d5dc372da31_html_a188ed61b1cef0b9e8af45d5dc372da31"><div class="ttname"><a href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules_a188ed61b1cef0b9e8af45d5dc372da31.html#a188ed61b1cef0b9e8af45d5dc372da31">nars.inference.SyllogisticRules.conditionalAbd</a></div><div class="ttdeci">static boolean conditionalAbd(Term cond1, Term cond2, Statement st1, Statement st2, Memory memory)</div><div class="ttdoc">{<(&&, S2, S3) ==> P>, <(&&, S1, S3) ==> P>} |- <S1 ==> S2> </div><div class="ttdef"><b>Definition:</b> <a href="../../d4/d6b/SyllogisticRules_8java_source.html#l00461">SyllogisticRules.java:461</a></div></div>
<div class="ttc" id="classnars_1_1entity_1_1Sentence_html"><div class="ttname"><a href="../../d6/d25/classnars_1_1entity_1_1Sentence.html">nars.entity.Sentence</a></div><div class="ttdoc">A Sentence is an abstract class, mainly containing a Term, a TruthValue, and a Stamp. </div><div class="ttdef"><b>Definition:</b> <a href="../../da/d1c/Sentence_8java_source.html#l00031">Sentence.java:31</a></div></div>
<div class="ttc" id="classnars_1_1io_1_1Symbols_a3c9984ce55deb7819945871ce1fa3a82_html_a3c9984ce55deb7819945871ce1fa3a82"><div class="ttname"><a href="../../dc/d71/classnars_1_1io_1_1Symbols_a3c9984ce55deb7819945871ce1fa3a82.html#a3c9984ce55deb7819945871ce1fa3a82">nars.io.Symbols.VAR_DEPENDENT</a></div><div class="ttdeci">static final char VAR_DEPENDENT</div><div class="ttdef"><b>Definition:</b> <a href="../../d5/da0/Symbols_8java_source.html#l00034">Symbols.java:34</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Term_ad85f45a7858737445d5158801774ff5f_html_ad85f45a7858737445d5158801774ff5f"><div class="ttname"><a href="../../d8/db8/classnars_1_1language_1_1Term_ad85f45a7858737445d5158801774ff5f.html#ad85f45a7858737445d5158801774ff5f">nars.language.Term.equals</a></div><div class="ttdeci">boolean equals(Object that)</div><div class="ttdoc">Equal terms have identical name, though not necessarily the same reference. </div><div class="ttdef"><b>Definition:</b> <a href="../../d8/df2/Term_8java_source.html#l00094">Term.java:94</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Variable_a2770bbc76b3aac48f49a1c15aaedab1b_html_a2770bbc76b3aac48f49a1c15aaedab1b"><div class="ttname"><a href="../../de/da5/classnars_1_1language_1_1Variable_a2770bbc76b3aac48f49a1c15aaedab1b.html#a2770bbc76b3aac48f49a1c15aaedab1b">nars.language.Variable.unify</a></div><div class="ttdeci">static boolean unify(char type, Term t1, Term t2)</div><div class="ttdoc">To unify two terms. </div><div class="ttdef"><b>Definition:</b> <a href="../../d2/de0/Variable_8java_source.html#l00109">Variable.java:109</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1BudgetFunctions_ac3df7e788b7a6e2b348d2ae7da7936c5_html_ac3df7e788b7a6e2b348d2ae7da7936c5"><div class="ttname"><a href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions_ac3df7e788b7a6e2b348d2ae7da7936c5.html#ac3df7e788b7a6e2b348d2ae7da7936c5">nars.inference.BudgetFunctions.forward</a></div><div class="ttdeci">static BudgetValue forward(TruthValue truth, Memory memory)</div><div class="ttdoc">Forward inference result and adjustment. </div><div class="ttdef"><b>Definition:</b> <a href="../../de/d4e/BudgetFunctions_8java_source.html#l00248">BudgetFunctions.java:248</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1BudgetFunctions_html"><div class="ttname"><a href="../../d7/d11/classnars_1_1inference_1_1BudgetFunctions.html">nars.inference.BudgetFunctions</a></div><div class="ttdoc">Budget functions for resources allocation. </div><div class="ttdef"><b>Definition:</b> <a href="../../de/d4e/BudgetFunctions_8java_source.html#l00031">BudgetFunctions.java:31</a></div></div>
<div class="ttc" id="classnars_1_1entity_1_1TruthValue_html"><div class="ttname"><a href="../../d3/db8/classnars_1_1entity_1_1TruthValue.html">nars.entity.TruthValue</a></div><div class="ttdoc">Frequency and confidence. </div><div class="ttdef"><b>Definition:</b> <a href="../../de/de7/TruthValue_8java_source.html#l00028">TruthValue.java:28</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1SyllogisticRules_a90588e33b6d7ca522e787ee476a2a012_html_a90588e33b6d7ca522e787ee476a2a012"><div class="ttname"><a href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules_a90588e33b6d7ca522e787ee476a2a012.html#a90588e33b6d7ca522e787ee476a2a012">nars.inference.SyllogisticRules.conditionalAna</a></div><div class="ttdeci">static void conditionalAna(Equivalence premise1, short index, Term premise2, int side, Memory memory)</div><div class="ttdoc">{<(&&, S1, S2) <=> P>, (&&, S1, S2)} |- P </div><div class="ttdef"><b>Definition:</b> <a href="../../d4/d6b/SyllogisticRules_8java_source.html#l00381">SyllogisticRules.java:381</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1CompoundTerm_a623c88183d85bd42464640937ea8ccb5_html_a623c88183d85bd42464640937ea8ccb5"><div class="ttname"><a href="../../d0/dee/classnars_1_1language_1_1CompoundTerm_a623c88183d85bd42464640937ea8ccb5.html#a623c88183d85bd42464640937ea8ccb5">nars.language.CompoundTerm.setComponent</a></div><div class="ttdeci">static Term setComponent(CompoundTerm compound, int index, Term t, Memory memory)</div><div class="ttdoc">Try to replace a component in a compound at a given index by another one. </div><div class="ttdef"><b>Definition:</b> <a href="../../d5/d0e/CompoundTerm_8java_source.html#l00476">CompoundTerm.java:476</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Statement_a96d4bf7bb99f48b6496cdb7457bc0e50_html_a96d4bf7bb99f48b6496cdb7457bc0e50"><div class="ttname"><a href="../../d1/d5e/classnars_1_1language_1_1Statement_a96d4bf7bb99f48b6496cdb7457bc0e50.html#a96d4bf7bb99f48b6496cdb7457bc0e50">nars.language.Statement.invalidStatement</a></div><div class="ttdeci">static boolean invalidStatement(Term subject, Term predicate)</div><div class="ttdoc">Check the validity of a potential Statement. </div><div class="ttdef"><b>Definition:</b> <a href="../../d2/d44/Statement_8java_source.html#l00191">Statement.java:191</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1SyllogisticRules_a9403109ff25044e65311d553d99a490d_html_a9403109ff25044e65311d553d99a490d"><div class="ttname"><a href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules_a9403109ff25044e65311d553d99a490d.html#a9403109ff25044e65311d553d99a490d">nars.inference.SyllogisticRules.analogy</a></div><div class="ttdeci">static void analogy(Term term1, Term term2, Sentence asym, Sentence sym, int figure, Memory memory)</div><div class="ttdoc">{<S ==> P>, <M <=> P>} |- <S ==> P> </div><div class="ttdef"><b>Definition:</b> <a href="../../d4/d6b/SyllogisticRules_8java_source.html#l00148">SyllogisticRules.java:148</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Variable_a27d52c132400491e698146c554cd89ac_html_a27d52c132400491e698146c554cd89ac"><div class="ttname"><a href="../../de/da5/classnars_1_1language_1_1Variable_a27d52c132400491e698146c554cd89ac.html#a27d52c132400491e698146c554cd89ac">nars.language.Variable.hasSubstitute</a></div><div class="ttdeci">static boolean hasSubstitute(char type, Term term1, Term term2)</div><div class="ttdoc">Check if two terms can be unified. </div><div class="ttdef"><b>Definition:</b> <a href="../../d2/de0/Variable_8java_source.html#l00195">Variable.java:195</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Equivalence_html"><div class="ttname"><a href="../../d1/d8b/classnars_1_1language_1_1Equivalence.html">nars.language.Equivalence</a></div><div class="ttdoc">A Statement about an Equivalence relation. </div><div class="ttdef"><b>Definition:</b> <a href="../../d3/dcc/Equivalence_8java_source.html#l00031">Equivalence.java:31</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1TruthFunctions_a0eded294e31894aad09eb976587a20d3_html_a0eded294e31894aad09eb976587a20d3"><div class="ttname"><a href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_a0eded294e31894aad09eb976587a20d3.html#a0eded294e31894aad09eb976587a20d3">nars.inference.TruthFunctions.comparison</a></div><div class="ttdeci">static TruthValue comparison(TruthValue v1, TruthValue v2)</div><div class="ttdoc">{<M ==> S>, <M ==> P>} |- <S <=> P> </div><div class="ttdef"><b>Definition:</b> <a href="../../df/d29/TruthFunctions_8java_source.html#l00255">TruthFunctions.java:255</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Term_html"><div class="ttname"><a href="../../d8/db8/classnars_1_1language_1_1Term.html">nars.language.Term</a></div><div class="ttdoc">Term is the basic component of Narsese, and the object of processing in NARS. </div><div class="ttdef"><b>Definition:</b> <a href="../../d8/df2/Term_8java_source.html#l00040">Term.java:40</a></div></div>
<div class="ttc" id="classnars_1_1io_1_1Symbols_a60c92a89535a54f54a72e20a5969536d_html_a60c92a89535a54f54a72e20a5969536d"><div class="ttname"><a href="../../dc/d71/classnars_1_1io_1_1Symbols_a60c92a89535a54f54a72e20a5969536d.html#a60c92a89535a54f54a72e20a5969536d">nars.io.Symbols.VAR_INDEPENDENT</a></div><div class="ttdeci">static final char VAR_INDEPENDENT</div><div class="ttdef"><b>Definition:</b> <a href="../../d5/da0/Symbols_8java_source.html#l00033">Symbols.java:33</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1TruthFunctions_a6c1cb2626ef3303a17b5bc84c9da732f_html_a6c1cb2626ef3303a17b5bc84c9da732f"><div class="ttname"><a href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_a6c1cb2626ef3303a17b5bc84c9da732f.html#a6c1cb2626ef3303a17b5bc84c9da732f">nars.inference.TruthFunctions.resemblance</a></div><div class="ttdeci">static TruthValue resemblance(TruthValue v1, TruthValue v2)</div><div class="ttdoc">{<S <=> M>, <M <=> P>} |- <S <=> P> </div><div class="ttdef"><b>Definition:</b> <a href="../../df/d29/TruthFunctions_8java_source.html#l00162">TruthFunctions.java:162</a></div></div>
<div class="ttc" id="namespacenars_1_1language_html"><div class="ttname"><a href="../../d0/d72/namespacenars_1_1language.html">nars.language</a></div><div class="ttdef"><b>Definition:</b> <a href="../../d5/d0e/CompoundTerm_8java_source.html#l00021">CompoundTerm.java:21</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1SyllogisticRules_a315c474733bb01f6f01e579221b417d4_html_a315c474733bb01f6f01e579221b417d4"><div class="ttname"><a href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules_a315c474733bb01f6f01e579221b417d4.html#a315c474733bb01f6f01e579221b417d4">nars.inference.SyllogisticRules.elimiVarDep</a></div><div class="ttdeci">static void elimiVarDep(CompoundTerm compound, Term component, boolean compoundTask, Memory memory)</div><div class="ttdoc">{(&&, <#x() –> S>, <#x() –> P>>, <M --> P>} |- <M --> S> </div><div class="ttdef"><b>Definition:</b> <a href="../../d4/d6b/SyllogisticRules_8java_source.html#l00533">SyllogisticRules.java:533</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1SyllogisticRules_a171a1f81d7f22d9cd0301220a79f4a63_html_a171a1f81d7f22d9cd0301220a79f4a63"><div class="ttname"><a href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules_a171a1f81d7f22d9cd0301220a79f4a63.html#a171a1f81d7f22d9cd0301220a79f4a63">nars.inference.SyllogisticRules.resemblance</a></div><div class="ttdeci">static void resemblance(Term term1, Term term2, Sentence belief, Sentence sentence, int figure, Memory memory)</div><div class="ttdoc">{<S <=> M>, <M <=> P>} |- <S <=> P> </div><div class="ttdef"><b>Definition:</b> <a href="../../d4/d6b/SyllogisticRules_8java_source.html#l00189">SyllogisticRules.java:189</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1CompoundTerm_acedae916705e9fa1669391a7d728b840_html_acedae916705e9fa1669391a7d728b840"><div class="ttname"><a href="../../d0/dee/classnars_1_1language_1_1CompoundTerm_acedae916705e9fa1669391a7d728b840.html#acedae916705e9fa1669391a7d728b840">nars.language.CompoundTerm.componentAt</a></div><div class="ttdeci">Term componentAt(int i)</div><div class="ttdoc">get a component by index </div><div class="ttdef"><b>Definition:</b> <a href="../../d5/d0e/CompoundTerm_8java_source.html#l00356">CompoundTerm.java:356</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1TruthFunctions_ad7f4353395335ad37f76d83ea8aae8e2_html_ad7f4353395335ad37f76d83ea8aae8e2"><div class="ttname"><a href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_ad7f4353395335ad37f76d83ea8aae8e2.html#ad7f4353395335ad37f76d83ea8aae8e2">nars.inference.TruthFunctions.anonymousAnalogy</a></div><div class="ttdeci">static TruthValue anonymousAnalogy(TruthValue v1, TruthValue v2)</div><div class="ttdoc">{(&&, <#x() ==> M>, <#x() ==> P>), S ==> M} |- <S ==> P> </div><div class="ttdef"><b>Definition:</b> <a href="../../df/d29/TruthFunctions_8java_source.html#l00434">TruthFunctions.java:434</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1SyllogisticRules_a08c8ce3ed165e9c09a7a379d9e871626_html_a08c8ce3ed165e9c09a7a379d9e871626"><div class="ttname"><a href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules_a08c8ce3ed165e9c09a7a379d9e871626.html#a08c8ce3ed165e9c09a7a379d9e871626">nars.inference.SyllogisticRules.detachment</a></div><div class="ttdeci">static void detachment(Sentence mainSentence, Sentence subSentence, int side, Memory memory)</div><div class="ttdoc">{<<M --> S> ==> <M --> P>>, <M --> S>} |- <M --> P> {<<M --> S> ==> <M –> P>>, <M --> P>} |- <M --> ...</div><div class="ttdef"><b>Definition:</b> <a href="../../d4/d6b/SyllogisticRules_8java_source.html#l00224">SyllogisticRules.java:224</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1TruthFunctions_a93ca820557fc8d18ef741bd33501126f_html_a93ca820557fc8d18ef741bd33501126f"><div class="ttname"><a href="../../d1/d58/classnars_1_1inference_1_1TruthFunctions_a93ca820557fc8d18ef741bd33501126f.html#a93ca820557fc8d18ef741bd33501126f">nars.inference.TruthFunctions.analogy</a></div><div class="ttdeci">static TruthValue analogy(TruthValue v1, TruthValue v2)</div><div class="ttdoc">{<S ==> M>, <M <=> P>} |- <S ==> P> </div><div class="ttdef"><b>Definition:</b> <a href="../../df/d29/TruthFunctions_8java_source.html#l00143">TruthFunctions.java:143</a></div></div>
<div class="ttc" id="classnars_1_1storage_1_1Memory_aae366ea198c2340fef786120d5c2163b_html_aae366ea198c2340fef786120d5c2163b"><div class="ttname"><a href="../../d8/df4/classnars_1_1storage_1_1Memory_aae366ea198c2340fef786120d5c2163b.html#aae366ea198c2340fef786120d5c2163b">nars.storage.Memory.getCurrentBelief</a></div><div class="ttdeci">Sentence getCurrentBelief()</div><div class="ttdoc">The selected belief. </div><div class="ttdef"><b>Definition:</b> <a href="../../db/d0c/Memory_8java_source.html#l00647">Memory.java:647</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1CompoundTerm_html"><div class="ttname"><a href="../../d0/dee/classnars_1_1language_1_1CompoundTerm.html">nars.language.CompoundTerm</a></div><div class="ttdoc">A CompoundTerm is a Term with internal (syntactic) structure. </div><div class="ttdef"><b>Definition:</b> <a href="../../d5/d0e/CompoundTerm_8java_source.html#l00036">CompoundTerm.java:36</a></div></div>
<div class="ttc" id="classnars_1_1storage_1_1Memory_a077b38e451ff6e4217bdc2ff0bb08e70_html_a077b38e451ff6e4217bdc2ff0bb08e70"><div class="ttname"><a href="../../d8/df4/classnars_1_1storage_1_1Memory_a077b38e451ff6e4217bdc2ff0bb08e70.html#a077b38e451ff6e4217bdc2ff0bb08e70">nars.storage.Memory.doublePremiseTask</a></div><div class="ttdeci">void doublePremiseTask(Term newContent, TruthValue newTruth, BudgetValue newBudget)</div><div class="ttdoc">Shared final operations by all double-premise rules, called from the rules except StructuralRules...</div><div class="ttdef"><b>Definition:</b> <a href="../../db/d0c/Memory_8java_source.html#l00280">Memory.java:280</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Variable_html"><div class="ttname"><a href="../../de/da5/classnars_1_1language_1_1Variable.html">nars.language.Variable</a></div><div class="ttdoc">A variable term, which does not correspond to a concept. </div><div class="ttdef"><b>Definition:</b> <a href="../../d2/de0/Variable_8java_source.html#l00030">Variable.java:30</a></div></div>
<div class="ttc" id="classnars_1_1entity_1_1BudgetValue_html"><div class="ttname"><a href="../../db/d8e/classnars_1_1entity_1_1BudgetValue.html">nars.entity.BudgetValue</a></div><div class="ttdoc">A triple of priority (current), durability (decay), and quality (long-term average). </div><div class="ttdef"><b>Definition:</b> <a href="../../d8/d59/BudgetValue_8java_source.html#l00031">BudgetValue.java:31</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1CompoundTerm_a43c073fe9f5a36241c475a2bc8736800_html_a43c073fe9f5a36241c475a2bc8736800"><div class="ttname"><a href="../../d0/dee/classnars_1_1language_1_1CompoundTerm_a43c073fe9f5a36241c475a2bc8736800.html#a43c073fe9f5a36241c475a2bc8736800">nars.language.CompoundTerm.isCommutative</a></div><div class="ttdeci">boolean isCommutative()</div><div class="ttdoc">Check if the order of the components matters. </div><div class="ttdef"><b>Definition:</b> <a href="../../d5/d0e/CompoundTerm_8java_source.html#l00338">CompoundTerm.java:338</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Statement_ace4f80751d303c613e467163913bebf5_html_ace4f80751d303c613e467163913bebf5"><div class="ttname"><a href="../../d1/d5e/classnars_1_1language_1_1Statement_ace4f80751d303c613e467163913bebf5.html#ace4f80751d303c613e467163913bebf5">nars.language.Statement.getSubject</a></div><div class="ttdeci">Term getSubject()</div><div class="ttdoc">Return the first component of the statement. </div><div class="ttdef"><b>Definition:</b> <a href="../../d2/d44/Statement_8java_source.html#l00229">Statement.java:229</a></div></div>
<div class="ttc" id="classnars_1_1language_1_1Implication_html"><div class="ttname"><a href="../../da/db6/classnars_1_1language_1_1Implication.html">nars.language.Implication</a></div><div class="ttdoc">A Statement about an Inheritance relation. </div><div class="ttdef"><b>Definition:</b> <a href="../../d3/d1a/Implication_8java_source.html#l00031">Implication.java:31</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1SyllogisticRules_a698f01981603a38d9da0e48930095d50_html_a698f01981603a38d9da0e48930095d50"><div class="ttname"><a href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules_a698f01981603a38d9da0e48930095d50.html#a698f01981603a38d9da0e48930095d50">nars.inference.SyllogisticRules.abdIndCom</a></div><div class="ttdeci">static void abdIndCom(Term term1, Term term2, Sentence taskSentence, Sentence belief, int figure, Memory memory)</div><div class="ttdoc">{<M ==> S>, <M ==> P>} |- {<S ==> P>, </div><div class="ttdef"><b>Definition:</b> <a href="../../d4/d6b/SyllogisticRules_8java_source.html#l00097">SyllogisticRules.java:97</a></div></div>
<div class="ttc" id="classnars_1_1inference_1_1SyllogisticRules_a6ee55e2d5114b506fdf5c59ae00dcd19_html_a6ee55e2d5114b506fdf5c59ae00dcd19"><div class="ttname"><a href="../../d4/daa/classnars_1_1inference_1_1SyllogisticRules_a6ee55e2d5114b506fdf5c59ae00dcd19.html#a6ee55e2d5114b506fdf5c59ae00dcd19">nars.inference.SyllogisticRules.conditionalDedInd</a></div><div class="ttdeci">static void conditionalDedInd(Implication premise1, short index, Term premise2, int side, Memory memory)</div><div class="ttdoc">{<(&&, S1, S2, S3) ==> P>, S1} |- <(&&, S2, S3) ==> P> {<(&&, S2, S3) ==> P>, <S1 ==> S2>} |- <(&&...</div><div class="ttdef"><b>Definition:</b> <a href="../../d4/d6b/SyllogisticRules_8java_source.html#l00291">SyllogisticRules.java:291</a></div></div>
</div><!-- fragment --></div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="../../dir_ed82ebcd34e530b246c6fd9032262140.html">aruntime</a></li><li class="navelem"><a class="el" href="../../dir_19496ddff8e6c0f2b6654287ecb1a472.html">src</a></li><li class="navelem"><a class="el" href="../../dir_db9c5934f797909f7296c2c2017f7fc9.html">main</a></li><li class="navelem"><a class="el" href="../../dir_6d74390eb6d6287951075e525bcb9bed.html">java</a></li><li class="navelem"><a class="el" href="../../dir_51a24984472456d47100350cd31f9a7c.html">nars</a></li><li class="navelem"><a class="el" href="../../dir_ee323373cf7c53e5489dea03632cbb1d.html">inference</a></li><li class="navelem"><a class="el" href="../../d4/d6b/SyllogisticRules_8java.html">SyllogisticRules.java</a></li>
    <li class="footer">Generated on Sun Jan 10 2016 18:03:58 for opennars by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="../../doxygen.png" alt="doxygen"/></a> 1.8.9.1 </li>
  </ul>
</div>
</body>
</html>
